Troubleshooting common installation issues

How do I fix missing Skaffold installation errors?

Skaffold is a tool required by the Cloud Code. The plugin attempts to find the Skaffold binary on the system PATH. If you don't have Skaffold installed, or the plugin simply can't detect the installation (possibly due to PATH issues), you may encounter an error in the Run Configuration.

Could not find Skaffold installation error

To fix this, either

  • Install Skaffold and ensure that it is added to the PATH.
  • Ensure the Skaffold executable name is skaffold on Linux and Mac systems, or skaffold.exe on Windows.
  • If Skaffold is installed and it's still not detected, visit Settings > Google > Kubernetes, and manually browse to the executable. Manually select Skaffold executable

How do I fix 'executable not found on PATH' errors?

If, during deployment or continuous development, you are getting errors in the form of executable file not found in $PATH.

For example:

time="2018-11-01T12:46:38-04:00" level=fatal msg="exiting dev mode because the first build failed: building [gcr.io//my-proj]: tagging: pushing: getting auth config for gcr.io//my-proj:3c275201-dirty-50f870d: getting auth config: error getting credentials - err: exec: "docker-credential-gcr": executable file not found in $PATH, out: ``"

Then, you may be running into the problem where the IDE is not inheriting the shell environment variables. This can happen in some Linux environments when the PATH variables are defined in .bash_profile or .bash_rc and the IDE is launched from the GUI, causing the IDE not to see the PATH variables.

While, unfortunately, there isn't an optimal solution, the following actions are workarounds in Linux:

  • Launch the IDE from the terminal

    First, follow these instructions to enable a command-line launcher. Then launch the IDE from the terminal.

    For example, to launch IntelliJ IDEA from the terminal, navigate to the project you wish to open, then execute:

    idea .
    

    Similarly, to launch PyCharm, execute:

    charm .
    
  • Alternatively, set the PATH variables in a system-wide location such as /etc/environment.

How do I fix Maven wrapper errors in the hello-world example project?

If you are getting errors in the form:

  time="2019-03-08T11:13:45-05:00" level=fatal msg="watching files for artifact gcr.io/gcp-dev-tools/hello-spring-boot: listing files:
  listing files: getting jibMaven dependencies: unable to stat file Found "C:\Users\\google-cloud-intellij\kubernetes\examples\hello-spring-boot\.mvn\wrapper\maven-wrapper.jar": CreateFile Found "C:\Users\\google-cloud-intellij\kubernetes\examples\hello-spring-boot\.mvn\wrapper\maven-wrapper.jar": The filename, directory name, or volume label syntax is incorrect."
 
Then you may be running into this known issue.

As a workaround in the Spring Boot hello-world project, you can change the Skaffold project from the default project to the docker profile in your Kubernetes Run Configuration.

Changing the Skaffold project to the docker profile

Getting Support

To send feedback, report issues on GitHub, or ask a question on Stack Overflow.
هل كانت هذه الصفحة مفيدة؟ يرجى تقييم أدائنا:

إرسال تعليقات حول...

Cloud Code for IntelliJ