Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
sprutton1 committed Jun 6, 2024
1 parent 22cb2ab commit 33fed7d
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 36 deletions.
12 changes: 4 additions & 8 deletions .github/workflows/deploy-service.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,22 +17,18 @@ on:
type: string
required: true
description: "version to deploy"
secrets:
access_key:
required: true
secret_key:
required: true

jobs:
deploy:
environment: ${{ inputs.environment }}
name: Deploy Service
runs-on: ubuntu-latest
steps:
- name: Configure AWS credentials for production
uses: aws-actions/configure-aws-credentials@v2
uses: aws-actions/configure-aws-credentials@v3
with:
aws-access-key-id: ${{ secrets.access_key }}
aws-secret-access-key: ${{ secrets.secret_key }}
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_KEY }}
aws-region: us-east-1

- name: Deploy web
Expand Down
16 changes: 4 additions & 12 deletions .github/workflows/deploy-stack.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,7 @@ jobs:
uses: ./.github/workflows/invalidate-cache.yml
with:
environment: shared
secrets:
access_key: ${{ secrets.AWS_SHARED_PROD_ACCESS_KEY }}
secret_key: ${{ secrets.AWS_SHARED_PROD_SECRET_KEY }}
secrets: inherit

secrets:
needs: invalidate-cache
Expand All @@ -60,9 +58,7 @@ jobs:
environment: ${{ github.event.inputs.environment }}
service: ${{ github.event.inputs.service }}
version: ${{ github.event.inputs.version }}
secrets:
access_key: ${{ secrets[needs.secrets.outputs.aws_access_key] }}
secret_key: ${{ secrets[needs.secrets.outputs.aws_secret_key] }}
secrets: inherit

deploy-services:
needs: secrets
Expand All @@ -76,9 +72,7 @@ jobs:
environment: ${{ github.event.inputs.environment }}
service: ${{ matrix.service }}
version: ${{ github.event.inputs.version }}
secrets:
access_key: ${{ secrets[needs.secrets.outputs.aws_access_key] }}
secret_key: ${{ secrets[needs.secrets.outputs.aws_secret_key] }}
secrets: inherit

set-init:
needs: secrets
Expand All @@ -87,6 +81,4 @@ jobs:
environment: ${{ github.event.inputs.environment }}
service: ${{ github.event.inputs.service }}
version: ${{ github.event.inputs.version }}
secrets:
access_key: ${{ secrets[needs.secrets.outputs.aws_access_key] }}
secret_key: ${{ secrets[needs.secrets.outputs.aws_secret_key] }}
secrets: inherit
12 changes: 4 additions & 8 deletions .github/workflows/invalidate-cache.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,22 +7,18 @@ on:
type: string
required: true
description: "which environment to invalidate"
secrets:
access_key:
required: true
secret_key:
required: true

jobs:
invalidate-cache:
environment: ${{ inputs.environment }}
runs-on: ubuntu-latest
steps:
# invalidate Artifact Store Cloudfront so we get latest
- name: Configure AWS credentials for shared-prod
uses: aws-actions/configure-aws-credentials@v2
uses: aws-actions/configure-aws-credentials@v3
with:
aws-access-key-id: ${{ secrets.access_key }}
aws-secret-access-key: ${{ secrets.secret_key }}
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_KEY }}
aws-region: us-east-1
- name: Invalidate Artifacts Cache
run: |
Expand Down
12 changes: 4 additions & 8 deletions .github/workflows/set-init-version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,22 +15,18 @@ on:
type: string
required: true
description: "version to deploy"
secrets:
access_key:
required: true
secret_key:
required: true

jobs:
deploy:
name: Set init version
environment: ${{ inputs.environment }}
runs-on: ubuntu-latest
steps:
- name: Configure AWS credentials for production
uses: aws-actions/configure-aws-credentials@v2
uses: aws-actions/configure-aws-credentials@v3
with:
aws-access-key-id: ${{ secrets.access_key }}
aws-secret-access-key: ${{ secrets.secret_key }}
aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY }}
aws-secret-access-key: ${{ secrets.AWS_SECRET_KEY }}
aws-region: us-east-1

- name: Set init version
Expand Down

0 comments on commit 33fed7d

Please sign in to comment.