Skip to content

Commit

Permalink
Merge pull request #57 from depromeet/cicd
Browse files Browse the repository at this point in the history
feat: Github Action 수행 시 AWS System Manager에서 config 파일 가져옴
  • Loading branch information
umi0410 authored Dec 24, 2021
2 parents 053f580 + a642c98 commit f2f4f5e
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,18 @@ jobs:
mkdir -p rest-api/deploy
mkdir -p api-gateway/deploy
- name: Configure AWS credentials from Test account
uses: aws-actions/configure-aws-credentials@v1
with:
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
aws-region: ap-northeast-2

- name: Copy config file
run: |
echo '${{ secrets.REST_CONFIG_DEV }}' > rest-api/config/dev.yml
echo '${{ secrets.SERVICE_ACCOUNT_DEV }}' > rest-api/config/service-account-dev.json
echo '${{ secrets.GATEWAY_CONFIG_DEV }}' > api-gateway/config/dev.yml
aws ssm get-parameter --name ${{ secrets.REST_PARAMETER_NAME_DEV }} --query "Parameter.Value" --output text > rest-api/config/dev.yml
aws ssm get-parameter --name ${{ secrets.SERVICE_ACCOUNT_PARAMETER_NAME_DEV }} --query "Parameter.Value" --output text > rest-api/config/service-account-dev.json
aws ssm get-parameter --name ${{ secrets.GATEWAY_PARAMETER_NAME_DEV }} --query "Parameter.Value" --output text > api-gateway/config/dev.yml
- name: Build rest-api
working-directory: rest-api
Expand Down

0 comments on commit f2f4f5e

Please sign in to comment.