0

I have interrupted a mvn gcloud:deploy command and I couldn't redeploy because this error message kept coming up. I had deleted all self generated buckets from GCS, but still no different outcome from this.

[INFO] If this is your first deployment, this may take a while.../
[INFO]                                                            
[INFO] If this is your first deployment, this may take a while...done.
[INFO] 

[INFO] ERROR: (gcloud.preview.app.deploy) There is a Dockerfile in the current directory, 
and the runtime field in /target/appengine-staging/app.yaml is currently set to
[runtime: java]. To use your Dockerfile to build a custom runtime, set the runtime field 
in /target/appengine-staging/app.yaml to [runtime: custom]. To continue using the [java]
runtime, please omit the Dockerfile from this directory. 

[ERROR] Error: gcloud app command with exit code : 1

Since I suspected this "lock" was on Google's source files for a builder instance it later deletes, I did what it was complaining about, changed my runtime from java to custom on the app.yaml file and it redeployed.

deployed versions and its runtimes

I can no longer deploy my VM with a Java runtime, I still get the same error message. How do I perform a clean build to get rid of this phantom docker image?

Caio Iglesias
  • 594
  • 9
  • 24

1 Answers1

0

To clean the maven built target directory, you can do:

mvn clean gcloud:deploy

ludo
  • 226
  • 1
  • 4
  • Instead of refreshing the appengine-staging folder on Eclipse to make the Dockerfile show up, I went after gcloud command line util for information. Debugged deploy_command_util.py to find out that the path to the Dockerfile was right there under my nose: /target/appengine-staging. Since https://cloud.google.com/sdk/gcloud/ is not open sourced I cannot contribute to a more direct error message. There is an option to clear any previous docker image, but I believe a mvn clean gcloud:deploy is better than preventing the use of custom docker images. – Caio Iglesias Apr 01 '16 at 00:02