Skip to content

Instantly share code, notes, and snippets.

@rxhl
Created September 5, 2021 15:05
Show Gist options
  • Save rxhl/d9c235fb373bc120f4a8867465b88557 to your computer and use it in GitHub Desktop.
Save rxhl/d9c235fb373bc120f4a8867465b88557 to your computer and use it in GitHub Desktop.
gcloud secrets create django_app_settings --replication-policy automatic
gcloud secrets versions add django_app_settings --data-file .env.prod
# Get the PROJECTNUM from your GCP project dashboard
gcloud secrets add-iam-policy-binding django_app_settings \
--member serviceAccount:<PROJECTNUM>@cloudbuild.gserviceaccount.com \
--role roles/secretmanager.secretAccessor
gcloud secrets describe django_app_settings
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment