mirror of
https://github.com/Sea-Haven-Industries/seahaven-site.git
synced 2026-09-30 07:43:16 +00:00
Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 6. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v4...v6) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
38 lines
921 B
YAML
38 lines
921 B
YAML
name: Deploy Static Site to S3
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
|
|
permissions:
|
|
id-token: write # Required for OIDC
|
|
contents: read # Allows checkout of repo
|
|
|
|
jobs:
|
|
deploy:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout repository
|
|
uses: actions/checkout@v6
|
|
|
|
- name: Configure AWS credentials using OIDC
|
|
uses: aws-actions/configure-aws-credentials@v2
|
|
with:
|
|
role-to-assume: arn:aws:iam::328440206208:role/githubdeploy_seahavensite
|
|
aws-region: us-east-1
|
|
|
|
- name: Sync files to S3
|
|
run: |
|
|
aws s3 sync . s3://seahaven.com \
|
|
--delete \
|
|
--exclude ".git/*" \
|
|
--exclude ".github/*" \
|
|
--exclude "*.md"
|
|
|
|
- name: Invalidate CloudFront cache
|
|
run: |
|
|
aws cloudfront create-invalidation \
|
|
--distribution-id EYK41AG0PO6XU \
|
|
--paths "/*"
|