-5
#!/bin/bash
gsutil -m cp -r dir gs://my-bucket

I write this code for transferring files from machine to GCS bucket..but I think I need to configure project and service account...please tell me the code for this.

Biffen
  • 6,249
  • 6
  • 28
  • 36

1 Answers1

0

The steps are basically:

  1. Create project
  2. Attach billing to the project
  3. Create the bucket
  4. Assign privilege to the bucket (if you open it up to all users for testing make sure you get rid of it or lock it down later)
  5. Upload/download an object via the gui
  6. Upload objects via gsutil

These two quickstarts should be followed in order and should cover everything you need to achieve what you're talking about.

  1. Quickstart Storage
  2. Quickstart Gsutil
Jake Nelson
  • 1,748
  • 13
  • 22