Skip to content

Commit

Permalink
Merge pull request #262 from nationalarchives/adam/code-deploy-theme-…
Browse files Browse the repository at this point in the history
…deployment

Added a GH Actions yaml file for website
  • Loading branch information
AdamBurnettNA authored Jan 24, 2023
2 parents d3bbdb8 + 64869d0 commit 0944a3e
Showing 1 changed file with 60 additions and 0 deletions.
60 changes: 60 additions & 0 deletions .github/workflows/deploy-code-website.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
---
name: Website Theme Deployment

permissions:
id-token: write
contents: write

on:
workflow_dispatch:
inputs:
deploy-environment:
type: choice
description: Environment
required: true
default: "dev"
options:
- dev
- staging
- live
release:
type: string
description: Release
required: false
default: ""

jobs:
deployment-run-dev:
if: ${{ inputs.deploy-environment == 'dev' }}
uses: nationalarchives/ds-github-actions/.github/workflows/website-theme-deploy.yml@main
with:
deploy-repo: "${{ github.event.repository.name }}"
deploy-environment: "${{ inputs.deploy-environment }}"
release: "${{ inputs.release }}"
branch: "${{ inputs.branch }}"
github-environment: "dev-deploy"
secrets:
AWS_ROLE_ARN: ${{ secrets.AWS_WEBSITE_ROLE_ARN_DEV }}
deployment-run-staging:
if: ${{ inputs.deploy-environment == 'staging' }}
uses: nationalarchives/ds-github-actions/.github/workflows/website-theme-deploy.yml@main
with:
deploy-repo: "${{ github.event.repository.name }}"
deploy-environment: "${{ inputs.deploy-environment }}"
release: "${{ inputs.release }}"
branch: "${{ inputs.branch }}"
github-environment: "staging-deploy"
secrets:
AWS_ROLE_ARN: ${{ secrets.AWS_WEBSITE_ROLE_ARN_STAGING }}
deployment-run-live:
if: ${{ inputs.deploy-environment == 'live' }}
uses: nationalarchives/ds-github-actions/.github/workflows/website-theme-deploy.yml@main
with:
deploy-repo: "${{ github.event.repository.name }}"
deploy-environment: "${{ inputs.deploy-environment }}"
release: "${{ inputs.release }}"
branch: "${{ inputs.branch }}"
github-environment: "live-deploy"
secrets:
AWS_ROLE_ARN: ${{ secrets.AWS_WEBSITE_ROLE_ARN_LIVE }}
...

0 comments on commit 0944a3e

Please sign in to comment.