Debugging an application

Cloud Code for IntelliJ allows you to easily debug your applications deployed to a Kubernetes cluster. You can debug an application on a local cluster (like Minikube or Docker Desktop), GKE, or any other Cloud provider.

Furthermore, with Cloud Code's debugging support, you don't have to worry about any manual setup like setting up port forwarding or injecting language-specific debug arguments in the right way. All you need to do is have a Cloud Code-ready Kubernetes application that includes a skaffold.yaml configuration file.


Click the debug action for Develop on Kubernetes run action icon to start the development cycle in debug mode on your Kubernetes cluster.

Starting the Kubernetes cluster development cycle in debug mode

The continuous development cycle will then initiate in debug mode.

Once the debugger can be attached, Cloud Code will attach a debug session:

Kubernetes debugger attached

You can now perform all the tasks you normally do when debugging local code, like setting breakpoints and stepping through code, except with the added advantage of debugging against a live Kubernetes cluster:

Kubernetes debugger session

To end the debugging session, click the stop icon on the Develop on Kubernetes Run Configuration.

Configuration Details

Cloud Code, powered by Skaffold under the hood, will automatically take care of the following for you:

  • Java, Kotlin

    • Adding an environment JAVA_TOOLS_OPTIONS with the appropriate JDWP configuration:


  • Node.js

    • Rewriting the entrypoint to invoke:

      node --inspect=localhost:9229

  • Go

    • Installing the dlv debugger using an Init Container and rewriting the entrypoint to invoke:

      dlv exec --headless --continue --accept-multiclient --listen=localhost:56268 --api-version=2, <app> --

  • Port forwarding the debug port so that the debugger can be attached.
  • Attaching a debugger to one or more debuggable containers in your application. If your application has multiple debuggable containers (containers whose language is supported by Cloud Code debug) configured in skaffold.yaml, then a debugger will be attached to each of these.

For more details, refer to the Skaffold debug documentation.

Getting Support

To send feedback, report issues on GitHub, or ask a question on Stack Overflow.