-
Notifications
You must be signed in to change notification settings - Fork 0
34 lines (32 loc) · 998 Bytes
/
deploy.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
name: Website deployer
on:
workflow_call:
inputs:
domain:
required: true
type: string
secrets:
AWS_ACCESS_KEY_ID:
required: true
AWS_SECRET_ACCESS_KEY:
required: true
ORG_GITHUB_TOKEN_FOR_CI:
required: false
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- name: "Set force deploy argument"
run: echo "EXTRA_DEPLOY_ARGS=--force" >> "$GITHUB_ENV"
if: ${{ contains(github.event.head_commit.message, '[force deploy]') }}
- uses: actions/checkout@v4
- uses: ruby/setup-ruby@v1
with:
bundler-cache: true
env:
BUNDLE_GITHUB__COM: x-access-token:${{ secrets.ORG_GITHUB_TOKEN_FOR_CI }}
- run: bundle exec deploy-website ${{ inputs.domain }} ${{ env.EXTRA_DEPLOY_ARGS }}
env:
AWS_REGION: us-east-1
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}