Skip to content

Publish

Publish #5

Workflow file for this run

# This is a basic workflow that is manually triggered
name: Publish
on:
workflow_dispatch:
workflow_call:
jobs:
stage:
# The type of runner that the job will run on
runs-on: ubuntu-latest
environment: staging
steps:
- name: Download build artifacts
uses: dawidd6/action-download-artifact@v6
with:
workflow: build.yml
- name: Upload site
uses: bwcxyk/s3-sync-action@1.0.0
with:
args: --acl public-read --follow-symlinks --delete
env:
AWS_S3_BUCKET: docs-staging.threatx.com
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_REGION: us-east-1
SOURCE_DIR: 'public'
release:
# The type of runner that the job will run on
runs-on: ubuntu-latest
needs: [stage]
environment: production
# Steps represent a sequence of tasks that will be executed as part of the job
steps:
- name: Download artifacts
uses: dawidd6/action-download-artifact@v6
with:
workflow: build.yml
- name: Upload
uses: bwcxyk/s3-sync-action@1.0.0
with:
args: --acl public-read --follow-symlinks --delete
env:
AWS_S3_BUCKET: docs.threatx.com
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }}
AWS_REGION: us-east-1
SOURCE_DIR: 'public'