DOA nodejs-docs-samples/appengine/hello-world/flexible ?
ChrisRus opened this issue · 3 comments
So, what's the problem w/this please?
Everything seems to check out and yet but the deployment fails on flex environment following directions https://cloud.google.com/appengine/docs/flexible/nodejs/quickstart#additional_prerequisites
cdr@alpental:~/code/samples/nodejs-docs-samples/appengine/hello-world/flexible$ gcloud app create --project=fuvpp5odrwkg1gk-su3qzq
You are creating an app for project [fuvpp5odrwkg1gk-su3qzq].
WARNING: Creating an App Engine application for a project is irreversible and the region
cannot be changed. More information about regions is at
<https://cloud.google.com/appengine/docs/locations>.
Please choose the region where you want your App Engine application
located:
[1] asia-east2 (supports standard and flexible and search_api)
[2] asia-northeast1 (supports standard and flexible and search_api)
[3] asia-northeast2 (supports standard and flexible and search_api)
[4] asia-northeast3 (supports standard and flexible and search_api)
[5] asia-south1 (supports standard and flexible and search_api)
[6] asia-southeast2 (supports standard and flexible and search_api)
[7] australia-southeast1 (supports standard and flexible and search_api)
[8] europe-west (supports standard and flexible and search_api)
[9] europe-west2 (supports standard and flexible and search_api)
[10] europe-west3 (supports standard and flexible and search_api)
[11] europe-west6 (supports standard and flexible and search_api)
[12] northamerica-northeast1 (supports standard and flexible and search_api)
[13] southamerica-east1 (supports standard and flexible and search_api)
[14] us-central (supports standard and flexible and search_api)
[15] us-east1 (supports standard and flexible and search_api)
[16] us-east4 (supports standard and flexible and search_api)
[17] us-west2 (supports standard and flexible and search_api)
[18] us-west3 (supports standard and flexible and search_api)
[19] us-west4 (supports standard and flexible and search_api)
[20] cancel
Please enter your numeric choice: 19
Creating App Engine application in project [fuvpp5odrwkg1gk-su3qzq] and region [us-west4]....done.
Success! The app is now created. Please use `gcloud app deploy` to deploy your first app.
cdr@alpental:~/code/samples/nodejs-docs-samples/appengine/hello-world/flexible$ gcloud app deploy
Initializing App Engine resources...failed.
ERROR: (gcloud.app.deploy) Error Response: [13] An internal error occurred while creating a Google Cloud Storage bucket.
cdr@alpental:~/code/samples/nodejs-docs-samples/appengine/hello-world/flexible$
Manually adding Google Cloud Builder gets me further. But, clearly something is fundamentally broken. But, what?
It should be simple for me to assess these errors, determine if somehow my environment / account / project / app is not configured correctly.
I have a more complicated, actual production example, deployed already in a flex environment. What I want is to replicate all the steps from scratch required to go from a good image build to a deployed image in a command line script so that we can deploy new apps w/confidence. I am back looking at hello-world flex to verify some base assumptions.
It's going poorly. Any advice about how to get passed these errors and get this working reliably would be appreciated.
cdr@alpental:~/code/samples/nodejs-docs-samples/appengine/hello-world/flexible$ gcloud app deploy --project=hello-world-flex-309100
Services to deploy:
descriptor: [/home/cdr/code/samples/nodejs-docs-samples/appengine/hello-world/flexible/app.yaml]
source: [/home/cdr/code/samples/nodejs-docs-samples/appengine/hello-world/flexible]
target project: [hello-world-flex-309100]
target service: [default]
target version: [20210328t172435]
target url: [https://hello-world-flex-309100.uc.r.appspot.com]
Do you want to continue (Y/n)? Y
Enabling service [appengineflex.googleapis.com] on project [hello-world-flex-309100]...
Operation "operations/acf.p2-654987148121-32b5a9b5-fd4c-4981-9637-266f956ca5d8" finished successfully.
Beginning deployment of service [default]...
Building and pushing image for service [default]
Started cloud build [3d0c4e92-b8ed-4a38-81b6-b871e707b0e1].
To see logs in the Cloud Console: https://console.cloud.google.com/cloud-build/builds/3d0c4e92-b8ed-4a38-81b6-b871e707b0e1?project=654987148121
--------------------------------------------------------------------------- REMOTE BUILD OUTPUT ---------------------------------------------------------------------------
starting build "3d0c4e92-b8ed-4a38-81b6-b871e707b0e1"
FETCHSOURCE
Fetching storage object: gs://staging.hello-world-flex-309100.appspot.com/us.gcr.io/hello-world-flex-309100/appengine/default.20210328t172435:latest#1616977574131939
Copying gs://staging.hello-world-flex-309100.appspot.com/us.gcr.io/hello-world-flex-309100/appengine/default.20210328t172435:latest#1616977574131939...
/ [1 files][ 21.7 KiB/ 21.7 KiB]
Operation completed over 1 objects/21.7 KiB.
BUILD
Starting Step #0
Step #0: Pulling image: gcr.io/gcp-runtimes/nodejs/gen-dockerfile@sha256:770f37e7042652138c7dac203fc35ef0218002515ddd9f311db1c6c54d6816aa
Step #0: sha256:770f37e7042652138c7dac203fc35ef0218002515ddd9f311db1c6c54d6816aa: Pulling from gcp-runtimes/nodejs/gen-dockerfile
Step #0: Digest: sha256:770f37e7042652138c7dac203fc35ef0218002515ddd9f311db1c6c54d6816aa
Step #0: Status: Downloaded newer image for gcr.io/gcp-runtimes/nodejs/gen-dockerfile@sha256:770f37e7042652138c7dac203fc35ef0218002515ddd9f311db1c6c54d6816aa
Step #0: gcr.io/gcp-runtimes/nodejs/gen-dockerfile@sha256:770f37e7042652138c7dac203fc35ef0218002515ddd9f311db1c6c54d6816aa
Step #0: Checking for Node.js.
Finished Step #0
Starting Step #1
Step #1: Already have image (with digest): gcr.io/kaniko-project/executor@sha256:f87c11770a4d3ed33436508d206c584812cd656e6ed08eda1cff5c1ee44f5870
Step #1: INFO[0000] Removing ignored files from build context: [node_modules .dockerignore Dockerfile npm-debug.log yarn-error.log .git .hg .svn app.yaml]
Step #1: INFO[0000] Downloading base image gcr.io/google-appengine/nodejs@sha256:058266594604d7967a371094f0631c32f93908c37e20c3354d22f1b3a63c9a17
Step #1: INFO[0016] Taking snapshot of full filesystem...
Step #1: INFO[0023] Using files from context: [/workspace]
Step #1: INFO[0023] COPY . /app/
Step #1: INFO[0023] Taking snapshot of files...
Step #1: INFO[0023] RUN /usr/local/bin/install_node '>= 12.20.0'
Step #1: INFO[0023] cmd: /bin/sh
Step #1: INFO[0023] args: [-c /usr/local/bin/install_node '>= 12.20.0']
Step #1: % Total % Received % Xferd Average Speed Time Time Time Current
Step #1: Dload Upload Total Spent Left Speed
100 31.1M 100 31.1M 0 0 40.3M 0 --:--:-- --:--:-- --:--:-- 40.2M
Step #1: % Total % Received % Xferd Average Speed Time Time Time Current
Step #1: Dload Upload Total Spent Left Speed
100 3835 100 3835 0 0 48242 0 --:--:-- --:--:-- --:--:-- 48544
Step #1: gpg: Signature made Wed Mar 17 22:21:36 2021 UTC using RSA key ID 643B6201 gpg: Can't check signature: public key not found
Step #1: The Node.js binary could not be verified.
Step #1: This means it may not be an officially released Node.js binary
Step #1: or may have been tampered with.
Step #1:
Step #1: Aborting the installation.
Step #1:
Step #1: The installation can be forced using the --ignore-verification-failure
Step #1: flag. However, it is strongly recommended that you install a version
Step #1: of Node.js that can be verified.
Step #1:
Step #1: Node installation failed: /opt/gcp/runtime/bootstrap_node exited with a non-zero exit code: 1
Step #1: error building image: error building stage: waiting for process to exit: exit status 1
Finished Step #1
ERROR
ERROR: build step 1 "gcr.io/kaniko-project/executor@sha256:f87c11770a4d3ed33436508d206c584812cd656e6ed08eda1cff5c1ee44f5870" failed: step exited with non-zero status: 1
---------------------------------------------------------------------------------------------------------------------------------------------------------------------------
ERROR: (gcloud.app.deploy) Cloud build failed. Check logs at https://console.cloud.google.com/cloud-build/builds/3d0c4e92-b8ed-4a38-81b6-b871e707b0e1?project=654987148121 Failure status: UNKNOWN: Error Response: [2] Build failed; check build logs for details
cdr@alpental:~/code/samples/nodejs-docs-samples/appengine/hello-world/flexible$
Can you try this in a new project? Might be a problem with Firestore or Datastore already being activated in that project.
Morning @fhinkel -- thanks for the response.
Can you try this in a new project? Might be a problem with Firestore or Datastore already being activated in that project.
I was intentionally trying to remove all free variables and had gcloud projects delete
everything and started fresh several times (or so I believe).
I am interested to understand if this can actually be automated via a script, or is just too brittle. So, I am happy to share logs and try experiments. Regards.