-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Setup deployments with github actions (#12)
We are moving from using circleci to github actions to take advantage of GH action OIDC access to AWS which is a more secure way to make deployments to AWS. Partially resolves issue Sceptre/sceptre#1401 depends on #11
- Loading branch information
Showing
6 changed files
with
42 additions
and
96 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
name: "workflow" | ||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
branches: | ||
- "*" | ||
jobs: | ||
pre-commit: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: 3.10 | ||
- uses: pre-commit/[email protected] | ||
deploy: | ||
runs-on: ubuntu-latest | ||
if: ${{ github.ref == 'refs/heads/master' }} | ||
needs: [ 'pre-commit' ] | ||
permissions: | ||
id-token: write | ||
contents: read | ||
steps: | ||
- name: 'Checkout' | ||
uses: actions/checkout@v4 | ||
- name: Assume AWS Role | ||
uses: aws-actions/configure-aws-credentials@v4 | ||
with: | ||
aws-region: eu-west-1 | ||
role-to-assume: arn:aws:iam::743644221192:role/gh-oidc-sceptre-aws | ||
role-session-name: GitHubActions-${{ github.repository_owner }}-${{ github.event.repository.name }}-${{ github.run_id }} | ||
role-duration-seconds: 1800 | ||
- name: 'Sceptre Deploy' | ||
uses: Sceptre/[email protected] | ||
with: | ||
sceptre_version: '4.3.0' | ||
sceptre_subcommand: 'launch prod --prune --yes' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.