Unable to uplaod file from my Windows Desktop to Cloud Storage bucket

I have a png file that i wish to upload from my Windows Desktop location to Google Cloud Storage bucket.

I am able to do that using the Console. However, i am unable to do it via gcloud:

gcloud storage cp Desktop/Gandalf.png gs://cat-bucket-test

The error that i am getting is as follows:

Completed files 0 | 0B
←[1;31mERROR:←[0m (gcloud.storage.cp) The following URLs matched no objects or files:
-Desktop/Gandalf.png

I have referred to the following resource:

https://cloud.google.com/storage/docs/uploading-objects#uploading-an-object

Can you please help me what i am missing here.

1 Like

Hello @mountaincode2 ,Welcome on Google Cloud Community.

Did you’ve tried to provide Absolute path for your file, instead of relative ?
like: C:\Documents\Newsletters\Summer2018.pdf

gcloud storage cp  gs://


cheers,
DamianS
LinkedIn medium.com Cloudskillsboost

1 Like

oh yup, that worked… thank you!

1 Like