Shwetadabgar
2 min readJan 18, 2021

--

Deploy a Nodejs application in GCP

  1. Have a account created in GCP using this link: https://console.cloud.google.com/
  2. Create a new project.

3. Click on the name which appears here and change it to the current project you created.

4. Go to App Engine -> services, here is were the deployed service will apeear once you complete deployment from your local.

5. Install google cloud sdk in your local :https://cloud.google.com/sdk/

6. Go to your local application and add a .yaml file for deployment. To learn more about the .yaml file creation check out this link :

https://cloud.google.com/appengine/docs/flexible/nodejs/configuring-your-app-with-app-yaml

7. Open command prompt at your project location and to login you can use the command:

gcloud auth login

8. To initialize your project use the command:

gcloud init

you can reinitialize by selecting 1. After which, it will ask you to specify your account and later, the application where you want to deploy your app.

9. To deploy give the command:

gcloud app deploy

10. Once the deployment is complete you can check the instance created in the GCP console.

--

--