How to manually deploy direct from Bitbucket to Google App Engine?

淺唱寂寞╮ 提交于 2019-12-20 04:33:04

问题


To manually deploy from a changed source on a Bitbucket repository (named trackfind) to a Google App Engine app (ID trackfind-1) , I'm doing this:

1 Go to https://console.cloud.google.com/home/dashboard?authuser=0&project=trackfind-1

2 Click Activate Google Cloud Shell:

3 Enter rm -rf trackfind

4 Enter git clone -b master https://chrisjj@bitbucket.org/chrisjj/trackfind.git

5 Enter appcfg.py -V 1 -A trackfind-1 update trackfind

6 Go to trackfind-1.appspot.com and verify changes are in place.

I'm sure there must be a quicker, direct way, e.g. avoiding cloning the repository each time. (I'm not interested in indirect methods e.g. using a local machine or an extra VM to run e.g. a third-party tool such as Jenkins.)

What is that way?

Note: I edited 3 from https://bitbucket.org/chrisjj/trackfind to https://chrisjj@bitbucket.org/chrisjj/trackfind.git , which avoids a prompt for the username.


回答1:


You could speedup things a bit by re-using the existing trackfind repository:

  1. Enter cd trackfind

  2. Enter git checkout master; git pull

This will only pull the delta changes since the last deployment, which can be significantly faster than re-pulling the entire repository from scratch, especially if it's a large repository and/or it has a long change history.



来源:https://stackoverflow.com/questions/40457465/how-to-manually-deploy-direct-from-bitbucket-to-google-app-engine

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!