6
5

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

Google Cloud Platform操作(Ubuntu 14.04 LTS)

6
Last updated at Posted at 2018-03-09

VMへファイルをアップロードしたい

適当なバケットを作ってファイルをアップロードします。
gsutil cp コマンドを使用します。[VALUES_IN_BRACKETS] は適切な値で置き換えます。

gsutil cp gs://[BUCKET_NAME]/[OBJECT_NAME] [OBJECT_DESTINATION]

逆にVMからファイルをバケットなどにコピーするには?

gsutil cp (対象ファイル) gs://[BUCKET_NAME]

↓のようなエラーが出た。理解しきれてないけどVMの構築方法次第ではエラーになるらしい。
AccessDeniedException: 403 Insufficient OAuth2 scope to perform this operation.
Acceptable scopes: https://www.googleapis.com/auth/cloud-platform

対処は下記を実行してGCPにログイン

gcloud auth login

ブラウザなどを経由してログインして下記へ認証コードを入力すればOK
Enter verification code:

タイムゾーンを日本にしたい(Ubuntu)

追記予定

6
5
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
6
5

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?