LoginSignup
1
0

More than 5 years have passed since last update.

Circle CI で GCRのイメージを使用する際の注意

Last updated at Posted at 2018-12-04

Circle CI で GCRのパスを指定する時の注意

GCRのパスを取得するときにauthのpasswordにあらかじめ設定しているCircle CIの環境変数をいれるのですが、これはBASE64でEncodeせずサービスアカウントのjsonを直接入れます。

version: 2.1
executors:
  default:
    working_directory: /root/project/
    docker:
      - image: gcr.io/$PROJECT_ID/appengine/go:latest
        auth:
          username: _json_key
          password: $GCLOUD_SERVICE_KEY
    environment:
      - TZ: "/usr/share/zoneinfo/Asia/Tokyo"

base64にencodeされた環境変数を指定していると以下のようなエラーがでます

Error response from daemon: Get https://gcr.io/v2/...: unknown: Unable to parse json key.

参考

1
0
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
1
0