Skip to content

Commit

Permalink
Add custom-actions file
Browse files Browse the repository at this point in the history
  • Loading branch information
sinehome committed Oct 3, 2023
1 parent 4bc2e9c commit c7a551f
Show file tree
Hide file tree
Showing 2 changed files with 52 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .github/actions/custom-actions/action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,9 @@ runs:
- name: Aselo Beta release custom action
if: inputs.helpline-name == format('AS_STG')
uses: ./.github/actions/custom-actions/aselo_beta_custom
- name: Aselo Production release custom action
if: inputs.helpline-name == format('AS_PRD')
uses: ./.github/actions/custom-actions/aselo_production_custom
- name: SafeSpot Staging release custom action
if: inputs.helpline-name == format('JM_STG')
uses: ./.github/actions/custom-actions/jamaica_staging_custom
Expand Down
49 changes: 49 additions & 0 deletions .github/actions/custom-actions/aselo_production_custom/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# Copyright (C) 2021-2023 Technology Matters
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published
# by the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU Affero General Public License for more details.
#
# You should have received a copy of the GNU Affero General Public License
# along with this program. If not, see https://www.gnu.org/licenses/.

name: 'Aselo Development release custom action'
description: 'Sets up environment variables related to non-standard additional features in use in the development environment'
inputs:
account-sid:
description: 'The Twilio Account SID for this account'
required: true
runs:
using: "composite"
steps:
# Line environment variables
- name: Set helpline Line Flex Flow SID
uses: "marvinpinto/action-inject-ssm-secrets@latest"
with:
ssm_parameter: "PROD_TWILIO_AS_LINE_FLEX_FLOW_SID"
env_variable_name: "LINE_FLEX_FLOW_SID"
- name: Set Line Channel Secret
uses: "marvinpinto/action-inject-ssm-secrets@latest"
with:
ssm_parameter: "PROD_LINE_AS_CHANNEL_SECRET"
env_variable_name: "LINE_CHANNEL_SECRET"
- name: Set Line Channel Access Token
uses: "marvinpinto/action-inject-ssm-secrets@latest"
with:
ssm_parameter: "PROD_LINE_AS_CHANNEL_ACCESS_TOKEN"
env_variable_name: "LINE_CHANNEL_ACCESS_TOKEN"
# Append environment variables
- name: Add LINE_FLEX_FLOW_SID
run: echo "LINE_FLEX_FLOW_SID=${{ env.LINE_FLEX_FLOW_SID }}" >> .env
shell: bash
- name: Add LINE_CHANNEL_SECRET
run: echo "LINE_CHANNEL_SECRET=${{ env.LINE_CHANNEL_SECRET }}" >> .env
shell: bash
- name: Add LINE_CHANNEL_ACCESS_TOKEN
run: echo "LINE_CHANNEL_ACCESS_TOKEN=${{ env.LINE_CHANNEL_ACCESS_TOKEN }}" >> .env
shell: bash

0 comments on commit c7a551f

Please sign in to comment.