File: setup_creds.sh

package info (click to toggle)
ruby-fog-google 1.29.3-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 2,160 kB
  • sloc: ruby: 14,258; makefile: 3
file content (10 lines) | stat: -rwxr-xr-x 325 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
#!/bin/bash

GOOGLE_PROJECT=$(curl "http://metadata.google.internal/computeMetadata/v1/project/project-id" -H "Metadata-Flavor: Google")

# fog needs the google project to be specified even if it uses application-default creds
cat >~/.fog <<EOL
test:
  google_project: ${GOOGLE_PROJECT}
  google_application_default: true
EOL