Skip to content

refactor workflows by decoupling processes #29

refactor workflows by decoupling processes

refactor workflows by decoupling processes #29

Workflow file for this run

name: Deploy Prod
on:
push:
branches:
- main
jobs:
deploy:
name: deploy-prod
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Use Node.js
uses: actions/setup-node@v4
with:
node-version: 20.x
cache: "npm"
- name: Install Dependencies
run: npm ci
- name: Update domain settings
uses: mikefarah/yq@master
with:
cmd: |
yq -i '.stages.prod.params.customDomainName = "${{ vars.CUSTOM_DOMAIN_NAME }}"' serverless-compose.yml
yq -i '.stages.prod.params.customDomainCertificateARN = "${{ vars.CUSTOM_DOMAIN_CERTIFICATE_ARN }}"' serverless-compose.yml
- name: Serverless Deploy
uses: serverless/github-action@v4
with:
args: deploy --stage prod
env:
SERVERLESS_LICENSE_KEY: ${{ secrets.SERVERLESS_LICENSE_KEY }}
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}