Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add resusable action to set app config with happy config #233

Merged
merged 2 commits into from
Jan 6, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions .github/actions/happy-config-set/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: Set app configs with happy config
description: This workflow will set an app config in a given environment using happy config
inputs:
app_config_name:
description: The name of the app config to set
required: true
type: string
app_config_value:
description: The value to set for the app config
required: true
type: string
happy_env:
description: The happy environment to set the app config in
required: true
type: string
runs:
using: "composite"
steps:
- name: Get Id Token
uses: actions/github-script@v6
with:
script: |
const id_token = await core.getIDToken()
core.setOutput('id_token', id_token)
core.exportVariable('id_token', id_token);
- name: Set env var
shell: bash
run: |
HAPPY_OIDC_ID_TOKEN=${{env.id_token}} happy config set ${{ inputs.env_var_name }} ${{ inputs.env_var_value }} --env ${{ inputs.happy_env }} --aws-profile ""
Loading