All Questions
Tagged with google-cloud-build node.js
59 questions
1
vote
1
answer
25
views
Run cloud-build triggers with Node.js library
I have a manual regional cloudbuild trigger, that uses Cloudbuild repositories (2nd gen) to make connections with github. I also need to pass substitution variables to the trigger.
Following this ...
0
votes
1
answer
174
views
How to get the callback of Google's OAuth2 to process it as a route handler?
I've deployed a web app through ExpressJs and I host it on Google Cloud Run.
The issue I'm having is that I'm not getting the callback from Google's OAuth2.
I have a route handler set as "app.get(...
0
votes
0
answers
494
views
Error: error:0480006C:PEM routines::no start line when using SSL certificate on Google Cloud?
I am getting this error when I deploy my docker image with my Node.js app in it to Google Cloud Build:
Error: error:0480006C:PEM routines::no start line
at /home/app/node_modules/.pnpm/[email protected]....
1
vote
1
answer
697
views
Google App Engine suddenly doesn't let me deploy my node.js app
I have a quite simple Node.js / typescript project that I was always able to build with npm run build and then deploy on Google App Engine Standard for Node.js with the command:
cloud app deploy --...
0
votes
2
answers
1k
views
Google Cloud Build - Step #4: node: --openssl-legacy-provider is not allowed in NODE_OPTIONS
I've been running an angular application on a google cloud app engine service for a few years. I made no changes to my .yaml file or anything related to my node versions and in my deployment pipeline ...
0
votes
2
answers
1k
views
How to use Google Cloud Build with Yarn 2+
How do I use Google Cloud Build with Yarn 2+? Do I need to create my own node image to support this or is there some shorthanded entrypoint like entrypoint: "yarn2"
Cloud Build with NodeJs:
...
3
votes
1
answer
1k
views
Google Cloud Build, Cloud Run, Cloud SQL Prisma Migration
I am trying to get a Google Cloud Build pipeline running with a Node.js application that is using Google Cloud Build, Cloud SQL (PostgreSQL) and Prisma for the ORM. I have started with the default ...
3
votes
1
answer
195
views
Is it possible to stream Cloud Build logs with the Node.js library?
Some context: Our Cloud Build process relies on manual triggers and about 8 substitutions to customize deploys to various firebase projects, hosting sites, and preview channels. Previously we used a ...
0
votes
1
answer
1k
views
How to deploy multiple cloud functions at a time through google cloud build by index.js file like in firebase
I have a situation where I want to deploy my whole index file through cloud build using cloudbuild.yaml file but didn't find any way to do so
like in firebase we do like firebase deploy --only ...
0
votes
0
answers
159
views
Getting Permission Error Deploying a Cloud Function with Private Dependency using Cloud Build
I'm trying to deploy a Cloud Function (Node.js + TypeScript) using Cloud Build.
What's unique is that my Cloud Function uses a private dependency, so that my package.json looks like this:
"...
0
votes
1
answer
348
views
deploy cloud functions using cloud build failed: Error: failed to get firebase project
=== Deploying to 'project_id'...
Step #1:
Step #1: I deploy functions
Step #1:
Step #1: Error: Failed to get Firebase project project_id. Please ensure the project exists and that your account has ...
0
votes
1
answer
313
views
Deploy cloud function using cloud build
This my package.json file
{
"name": "functions",
"description": "Cloud Functions for Firebase",
"scripts": {
"serve": "...
0
votes
0
answers
790
views
404 returned when trying to fetch ID token from inside docker container in cloud build
I have a NextJs app that uses an API hosted on Google Cloud Run during its static site generation (SSG). The SSG happens during the build step, which is performed inside a docker node.js container in ...
1
vote
1
answer
679
views
GCP project owner can't list builds or triggers
I have the owner role on a GCP project. I created 2 build triggers, which are visible to me in the console.
I want to list these triggers using a service account and the node.js client.
I made a ...
0
votes
1
answer
1k
views
Google Cloud App Engine - NestJS App deploys fine and runs instance, but can't access it
I am trying to host a NestJS application on Google App Engine. I'm using Cloud Build to deploy the app into App Engine after certain action on my GitHub repo.
Everything goes fine; the app builds and ...
0
votes
0
answers
462
views
ERROR: build step 1 "gcr.io/cloud-builders/npm:latest" failed: step exited with non-zero status: 3
I am trying built angular 8 dist using cloudbuild and deploying it on a vm
GitHub link of my angular 8 app https://github.com/nishitkumar123/angular-on-gcp
cloudbuild.yaml
steps:
name: "gcr.io/...
0
votes
2
answers
347
views
GAE deployment throwing Error Response: [13] The system encountered a fatal error
Encountering problem when deploying Node/React application to App engine using the command: gcloud app deploy --quiet --no-promote --no-stop-previous-version --version={VERSION_NUMBER}. This didn't ...
0
votes
1
answer
253
views
Does GCP Cloud Build Docker remove files created during the Dockerfile execution?
I have a build step in the docker file that generates some files. Since I also need those files locally (when testing) I have the generation of them not in Cloud Build itself but in the Dockerfile (...
0
votes
0
answers
236
views
Cloud build deployment of Angular/Node.js to App Engine times out at "npm ci --quiet" command
I am deploying an angular/Nodejs app to App engine. The application was getting deployed to as expected about 10 months ago. Today it is timing out after 10 minutes at the npm ci --quiet command. This ...
1
vote
1
answer
578
views
Google Cloud Builder for Angular fails during Node SASS installation using Cloud Builders Community image
Steps I've done so far:
I've created a Google Cloud Repository
I've created a Cloud Build Trigger and linked it to my GitHub account and repo and matched the branch name exactly ^staging$
And now ...
4
votes
3
answers
7k
views
Specifying Node.js version for Google Cloud App Engine Flexible
I'm trying to deploy a GCloud App Engine Flexible service. I have a yaml file, in which it has the Node.js runtime and the env specified.
runtime: nodejs
env: flex
As the documentation says "You ...
0
votes
1
answer
681
views
reading .env file from node - env file is not published
I am trying to read .env file using "dotenv" package but it returns undefined from process.env.DB_HOST after published to gcloud run. I see all files except for the .env file in root ...
0
votes
1
answer
504
views
Deploying a VueJs + Node app on App Engine w/ CloudBuild
My project is a VueJS frontend + Node Backend. The project is organized like this:
/api (all the backend logic, like uploading to GCS)
package.json
/ui (all front end logic)
package.json
...
1
vote
1
answer
1k
views
Cloud build completes with FAILURE status; other issues follow
I was following along this video from Google Tech Build youtube channel on their new "Serverless Expeditions" series which is really great and neat. Highly recommended.
This is my first time ...
0
votes
1
answer
92
views
Deployment to App Engine using Cloudbuild failing
I've built a Node + Vue JS project that is structured with different directories for the frontend and backend code. /api is the backend code with its own package.json and ui is the frontend code with ...
0
votes
1
answer
223
views
Failed to start and then listen on the port
I have an NodeJS app that I want to deploy on Google Cloud Run.
I have Google Cloud Build configured to build container from dockerfile whenever something has been pushed ona master branch and after ...
-1
votes
1
answer
2k
views
"Please run: npx browserslist@latest --update-db2" when deploying a Google App Engine app using Google Cloud Build
Browserslist: caniuse-lite is outdated. Please run: npx browserslist@latest --update-db2
After I deployed my Google App Engine app using Google Cloud Build,
I got the above error. So I ran the ...
0
votes
1
answer
874
views
Cloudbuild can't find my package.json from my Vue app
I am attempting to deploy a Vue JS app to GCP App Engine via GCP Cloud Build. I've followed the instructions and have created a cloudbuild.yaml file in a separate directory from the app.yaml file. The ...
0
votes
1
answer
173
views
Error when deploying to App Engine through Cloud Build
When I manually run gcloud app deploy from Cloud Shell, I am able to deploy the application to App Engine and it works.
But when I try to do the same via Cloud Build, the build succeeds, but the ...
1
vote
1
answer
648
views
NestJS Project on Google App Engine shows error “Could not write file”
I try to deploy my nestJS application in app engine with standard env instance. But I received this error:
0mCould not write file '/workspace/dist/my/ts/file': EROFS: read-only file system, open '/...
1
vote
1
answer
459
views
How to use relative dependencies when deploying to App Engine with Cloud Build
I have a full stack project that have some common modules, mostly type definitions. I want to keep them in the same repository to keep a consistent state of my application. However, the deploying ...
1
vote
1
answer
2k
views
GCP Cloud Run Socket.IO Timeout
I'm currently deploying my Socket.IO server with Node.js/Express on Google Cloud Platform using Cloud Build + Run, and it works pretty well.
The issue I'm having is that GCP automatically times out ...
0
votes
1
answer
284
views
Do I need to add node_modules to .gcloudignore when running "gcloud builds submit ./project-folder"?
This is my project structure:
project/
node_modules/
src/
.gcloudignore
cloudbuild.yaml
Dockerfile
package.json
Here is how I'm building it:
gcloud builds submit ./project --config=./...
5
votes
2
answers
3k
views
Where to store environment variables in App Engine for CI/CD Pipeline?
I am deploying my first application on the cloud and I'm trying to setup my env vars.
From what I understand, they are set in the app.yaml file. But if that file is pushed to the repo, it would then ...
0
votes
1
answer
1k
views
Cloud Build - Credentials error using exec wrapper to connect to Cloud SQL Proxy + other GCP resources
I'm attempting to use the exec-wrapper in a Cloud Build step to run the Cloud SQL Proxy and run a Node script to do a custom database migration. Here is what my cloud build config looks like:
steps:
- ...
1
vote
0
answers
284
views
Cloud Run connect to cloud SQL(postgres) using socket Connection timeout issue
I'm trying to connect the cloud sql in Cloud run. the same application works well with Google app engine. but the cloud run gives connection timeout error.
"unhandled error Error: Timeout in ...
1
vote
2
answers
3k
views
Cloud Build failing to npm install a NodeJS project
I'm running the following command in my cloudbuild.yaml file:
- name: "gcr.io/cloud-builders/npm"
args: ["install"]
This command ran correctly on 30th July, but on the 5th ...
0
votes
1
answer
297
views
Angular universal timeout with cloud build on firebase function
I have Angular Universal project deployed on firebase and using firebase functions to serve the server-side also using cloud build to trigger the build , the problem it just stuck in server build ...
0
votes
1
answer
679
views
How to run tests for a node app deployed on Cloud Run with Cloud Build
I have a nodejs API running on Google cloud Run and am using Cloud Build for continuous Deployment.
I would need to run tests so that in case of errors found, cloud Build does not deploy the image to ...
3
votes
1
answer
1k
views
How to deploy only an affected nx service to GCP APP Engine
Given that I have an NX application with multiple services, and I want to do continuous deployment of only affected service/s to App Engine, how can I point to a given service.yaml (or multiple) ...
-1
votes
1
answer
327
views
Using two CloudBuild images in one step
I have run into a problem where I need to run both Java+Android and NodeJS in the same CloudBuild "step".
My current situation is that I'm trying to build a react-native project within ...
-2
votes
2
answers
268
views
Steps for Cloud Function + Cloud Build API + Node 10?
As I received email from Firbase to upgrade Firebase Cloud Function with Node 10 and Cloud Build API.
I have done all the steps as below:
Updated to the "Blaze" pay-as-you-go Plan
Updated ...
0
votes
0
answers
2k
views
CI with google cloud build and unit testing Jest in NodeJS
I'm setting up a CI/CD pipeline using Google cloud build, I'm doing 3 simple steps : install, test and deploy, here is my CloudBuild.yaml file :
steps:
- name: "gcr.io/cloud-builders/npm"
...
0
votes
1
answer
2k
views
Could you please verify my cloudbuild.yaml file?
I am new to setup CI CD pipeline for my nodejs application using GCP cloud build. Below are the steps that I have done:
Writing the cloudbuild.yaml file. Done
Mirrored the bitbucket repository in my ...
0
votes
1
answer
1k
views
invalid build: invalid image name "gcr.io/sam-api-267023/https://sam-api-267023.appspot.com/:a83bcce15e7329d9925cda40a17a9f588afe478f"
I have a project running on Google App Engine and to deploy it, I have a GCloud build connected to a GitHub webhook. Anytime I push to my master branch it deploys.
Recently though I've been ...
7
votes
2
answers
2k
views
GCP Cloud build ignores timeout settings
I use Cloud Build for copying the configuration file from storage and deploying the app to App Engine flex.
The problem is that the build fails every time when it lasts more than 10 minutes. I've ...
4
votes
1
answer
1k
views
NPM authentication for private module with Google App Engine
I am trying to deploy a node application which imports a private npm module to Google App Engine. I'm still stuck at npm install failing due to Unable to authenticate, need: Basic realm="GitHub ...
1
vote
1
answer
769
views
How to expose build step results using docker + Google Cloud Build
I'm trying to build a next.js application on Google Cloud Build in a monorepo using Yarn workspaces. I've found that one of our slowest points during the build process is installing node modules since ...
1
vote
3
answers
2k
views
google cloud build - functions@: The engine "node" is incompatible with this module. Expected version "10"
I'm setting up cloud build trigger, how to set node version properly? this is what I get:
Already have image (with digest): gcr.io/cloud-builders/yarn
yarn install v1.9.4
info No ...
2
votes
2
answers
2k
views
Google App Engine deployment with private git repo in package.json
I have a dependency to a private Bitbucket repo in my package.json
{
"my-dependency": "git+ssh://[email protected]/something/my-dependency.git"
}
I followed the instructions given in [1] and [2] ...