Skip to content

Openverse is a search engine for openly-licensed media. This monorepo includes all application code.

Set and use `GH_SLACK_USERNAME_MAP` as an environment variable (#2055)

Krystle Salazarf5ec9092d72b
diff --git a/.github/actions/staging-frontend-deploy/action.yml b/.github/actions/staging-frontend-deploy/action.yml
index a6911d71d..c743cd80b 100644
--- a/.github/actions/staging-frontend-deploy/action.yml
+++ b/.github/actions/staging-frontend-deploy/action.yml
@@ -25,10 +25,12 @@ runs:
steps:
- name: Set the Slack user
shell: python
+ env:
+ GH_SLACK_USERNAME_MAP: ${{ secrets.GH_SLACK_USERNAME_MAP }}
run: |
import json
import os
- mapping = json.loads("${{ toJSON(secrets.GH_SLACK_USERNAME_MAP) }}")
+ mapping = json.loads("${{ toJSON(env.GH_SLACK_USERNAME_MAP) }}")
github_user = "${{ github.triggering_actor }}"
slack_id = mapping[github_user]
with open(os.getenv('GITHUB_ENV'), "a") as env_file: