Bài đăng

Hiển thị các bài đăng có nhãn gcp

git error when deploying Google App Engine Flexible with sample code

Hình ảnh
Deploy Hello World app For setup, follow this guidance here:  https://cloud.google.com/appengine/docs/flexible/go/quickstart If we don't do these setup steps, an error  exec: "gcc": executable file not found in $PATH  may occur when running  gcloud app deploy My environment: $ cat /etc/system-release CentOS Linux release 7.9.2009 (Core) $ git version git version 1.8.3.1 $ go version go version go1.15.14 linux/amd64 Download go sample Hello World app and try running it locally. $ git clone github.com/GoogleCloudPlatform/golang-samples $ cd golang-samples/appengine_flexible/helloworld # Run it locally $ go run *.go There was an error:  fatal: git fetch-pack: expected shallow list go: cloud.google.com/go/bigtable@v1.4.0 requires google.golang.org/api@v0.28.0 requires honnef.co/go/tools@v0.0.1-2020.1.3 requires golang.org/x/mod@v0.0.0-20190513183733-4bf6d317e70e: invalid version: git fetch --unshallow -f origin in /xxx/go/pkg/mod/cache/vcs/13...

3 steps to to make a Cloud Storage bucket public

We need 3 configurations to make a bucket public to everyone. 1. Remove public access prevention A bucket cannot be accessed by public as the default. So we need to remove public access prevention. Go to the  Bucket details  >  Permissions  tab >  Public access  section Click  Remove public access prevention  and confirm 2. Add permission for  allUsers  (e.g. to view objects) Go to the  Bucket details  >  Permissions  tab >  Permissions  section Click  Add  and fill in the following information, then click  Save New principals:  allUsers  or  allAuthenticatedUsers Select a role:  Storage Object Viewer 3. Change  Access control  to  Fine-grained Go to the  Bucket details  >  Configuration  tab >  Permissions Edit  Access control  field to  Fine-grained References https://cloud.google.com/storage/docs/ac...