Skip to content

Site Sync, Build and Deploy #97

Site Sync, Build and Deploy

Site Sync, Build and Deploy #97

name: Site Sync, Build and Deploy
on:
workflow_dispatch:
schedule:
- cron: '*/15 * * * *'
jobs:
sync-build-deploy:
runs-on: ubuntu-latest
permissions:
id-token: write
contents: write
defaults:
run:
working-directory: site
steps:
- uses: actions/checkout@v6
- uses: fregante/setup-git-user@v2
- id: gcp-auth
uses: google-github-actions/auth@v3
with:
workload_identity_provider: 'projects/1016117555218/locations/global/workloadIdentityPools/github-actions-pool/providers/github-oidc-provider'
service_account: 'gdrive-obsidian@daily-notes-obsidian-gdrive.iam.gserviceaccount.com'
- uses: ./.github/actions/site-setup-and-build
- name: Run tests
run: go test ./...
- name: Configure AWS credentials
uses: aws-actions/configure-aws-credentials@v6
with:
role-to-assume: ${{ secrets.AWS_ROLE_ARN }}
aws-region: us-east-2
- name: Sync, commit, build and upload
run: ./sync-upload.sh