gcloud and gsutil


gcloud and gsutil

https://cloud.google.com/sdk/docs/downloads-interactive#linux-mac
First install the gcloud sdk
1. curl https://sdk.cloud.google.com | bash

2. Restart your shell

3. gcloud init

you will get the command from server what you need to run on you local system to get the string(command) that string you have to use on server then we will get Authenticated

Check auth list____________________________________
gcloud auth list

Revoke auth List___________________________________
gcloud auth revoke

List all buckets___________________________________
gcloud alpha storage ls --project=fishcon

Configure the project______________________________
gcloud config set projectid

Copy file to GCS-Bucket____________________________
gsutil cp test.txt gs://bucker-test
gsutil cp gs://bucket-test/test.pdf gs://bucket-testnew

gsutil cp local-location/filename gs://bucketname/
gsutil cp -r folder-name gs://bucketname/
gsutil -m cp -r folder-name gs://bucketname
gsutil cp gs://bucketname/filename local-location
gsutil cp -r gs://bucketname/folder-name local-location
gsutil -m cp -r gs://bucketname/folder-name local-location


There are no comments yet.
Your message is required.
Markdown cheatsheet.