Fix sync_dir_to path in sync-assets.yml #5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Sync build assets to CDN | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
sync: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Website | |
uses: actions/checkout@v4 | |
- name: Setup Node.js | |
uses: actions/setup-node@v4 | |
with: | |
node-version: '20' | |
cache: 'npm' | |
- name: Install dependencies | |
run: npm install | |
- name: Build | |
run: npm run build | |
env: | |
AUTH_SECRET: "secret" # prevent error on build | |
RAZORPAY_KEY: "test_key" | |
RAZORPAY_SECRET: "test_secret" | |
- name: Sync build assets | |
uses: patrickwyler/[email protected] | |
with: | |
secrets: ${{ secrets.GOOGLE_SERVICE_ACCOUNT_CREDENTIALS }} | |
bucket: "tiara-assets" | |
exclude: '.*\.md$|\.gitignore$|\.git/.*$|\.github/.*$' | |
sync_dir_from: ".next/static" | |
sync_dir_to: "_next/static" | |