From 6eee50af1966eabb0a8feb251ac26db2b003e7e8 Mon Sep 17 00:00:00 2001 From: Jimmy Royer Date: Thu, 28 Oct 2021 17:20:12 -0400 Subject: [PATCH] Added staging vars in github env vars (#308) * Added staging vars in github env vars * Moved staging vars into default vars section * Empty opsgenie var for staging env. --- .github/workflows/merge_to_main_production.yml | 1 - .github/workflows/merge_to_main_staging.yml | 1 + .github/workflows/pull_requests.yml | 12 ++++++++++-- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/.github/workflows/merge_to_main_production.yml b/.github/workflows/merge_to_main_production.yml index 9b9c02b65..e2d0f93d0 100644 --- a/.github/workflows/merge_to_main_production.yml +++ b/.github/workflows/merge_to_main_production.yml @@ -14,7 +14,6 @@ defaults: shell: bash env: - # Terraform environment variables AWS_ACCESS_KEY_ID: ${{ secrets.PRODUCTION_AWS_ACCESS_KEY_ID }} AWS_SECRET_ACCESS_KEY: ${{ secrets.PRODUCTION_AWS_SECRET_ACCESS_KEY }} AWS_REGION: ca-central-1 diff --git a/.github/workflows/merge_to_main_staging.yml b/.github/workflows/merge_to_main_staging.yml index 76b034f4f..bd52e9735 100644 --- a/.github/workflows/merge_to_main_staging.yml +++ b/.github/workflows/merge_to_main_staging.yml @@ -26,6 +26,7 @@ env: TF_VAR_slack_channel_warning_topic: "notification-staging-ops" TF_VAR_slack_channel_critical_topic: "notification-staging-ops" TF_VAR_slack_channel_general_topic: "notification-staging-ops" + TF_VAR_cloudwatch_opsgenie_alarm_webhook: "" TF_VAR_admin_client_secret: ${{ secrets.STAGING_ADMIN_CLIENT_SECRET }} TF_VAR_auth_tokens: ${{ secrets.STAGING_AUTH_TOKENS }} TF_VAR_dangerous_salt: ${{ secrets.STAGING_DANGEROUS_SALT }} diff --git a/.github/workflows/pull_requests.yml b/.github/workflows/pull_requests.yml index 7f8e39439..518d7fdfa 100644 --- a/.github/workflows/pull_requests.yml +++ b/.github/workflows/pull_requests.yml @@ -18,8 +18,7 @@ env: TERRAFORM_VERSION: 0.14.4 TERRAGRUNT_VERSION: v0.26.0 TARGET_ENV_PATH: staging - TF_VAR_rds_cluster_password: fake_password_for_plan_123456 - TF_VAR_cloudwatch_slack_webhook: "https://example.com/slack/webhook" + TF_VAR_admin_client_secret: ${{ secrets.STAGING_ADMIN_CLIENT_SECRET }} TF_VAR_admin_client_user_name: ${{ secrets.STAGING_ADMIN_CLIENT_USER_NAME }} TF_VAR_api_host_name: ${{ secrets.STAGING_API_HOST_NAME }} @@ -27,12 +26,21 @@ env: TF_VAR_asset_upload_bucket_name: ${{ secrets.STAGING_ASSET_UPLOAD_BUCKET_NAME }} TF_VAR_auth_tokens: ${{ secrets.STAGING_AUTH_TOKENS }} TF_VAR_base_domain: ${{ secrets.STAGING_BASE_DOMAIN }} + TF_VAR_cloudwatch_opsgenie_alarm_webhook: "" + TF_VAR_cloudwatch_slack_webhook: ${{ secrets.STAGING_CLOUDWATCH_SLACK_WEBHOOK }} + TF_VAR_cloudwatch_slack_webhook_critical_topic: ${{ secrets.STAGING_CLOUDWATCH_SLACK_WEBHOOK }} + TF_VAR_cloudwatch_slack_webhook_general_topic: ${{ secrets.STAGING_CLOUDWATCH_SLACK_WEBHOOK }} + TF_VAR_cloudwatch_slack_webhook_warning_topic: ${{ secrets.STAGING_CLOUDWATCH_SLACK_WEBHOOK }} TF_VAR_csv_upload_bucket_name: ${{ secrets.STAGING_CSV_UPLOAD_BUCKET_NAME }} TF_VAR_dangerous_salt: ${{ secrets.STAGING_DANGEROUS_SALT }} TF_VAR_documents_bucket: ${{ secrets.STAGING_DOCUMENTS_BUCKET }} TF_VAR_document_download_api_host: ${{ secrets.STAGING_DOCUMENT_DOWNLOAD_API_HOST }} TF_VAR_mlwr_host: "false" TF_VAR_notification_queue_prefix: eks-notification-canada-ca + TF_VAR_slack_channel_critical_topic: notification-staging-ops + TF_VAR_slack_channel_general_topic: notification-staging-ops + TF_VAR_slack_channel_warning_topic: notification-staging-ops + TF_VAR_rds_cluster_password: ${{ secrets.STAGING_RDS_CLUSTER_PASSWORD }} TF_VAR_redis_url: ${{ secrets.STAGING_REDIS_URL }} TF_VAR_secret_key: ${{ secrets.STAGING_SECRET_KEY }} TF_VAR_sqlalchemy_database_reader_uri: ${{ secrets.STAGING_SQLALCHEMY_DATABASE_READER_URI }}