Skip to content

Commit 70403ff

Browse files
authored
fix(ci): split FTP asset deployment (#18)
1 parent e7a2b00 commit 70403ff

1 file changed

Lines changed: 15 additions & 1 deletion

File tree

‎.github/workflows/deploy.yml‎

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ jobs:
3535
echo "Build output files:"
3636
find out/ -type f | head -10
3737
38-
- name: Deploy Next.js assets
38+
- name: Deploy Next.js assets (excluding app chunks)
3939
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
4040
uses: SamKirkland/FTP-Deploy-Action@4.3.0
4141
with:
@@ -44,6 +44,20 @@ jobs:
4444
password: ${{ secrets.FTP_PASSWORD }}
4545
local-dir: ./out/_next/
4646
server-dir: ./_next/
47+
state-name: .ftp-deploy-sync-state.json
48+
exclude: |
49+
**/static/chunks/app/**
50+
51+
- name: Deploy Next.js app chunks
52+
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
53+
uses: SamKirkland/FTP-Deploy-Action@4.3.0
54+
with:
55+
server: ${{ secrets.FTP_HOST }}
56+
username: ${{ secrets.FTP_USERNAME }}
57+
password: ${{ secrets.FTP_PASSWORD }}
58+
local-dir: ./out/_next/static/chunks/app/
59+
server-dir: ./_next/static/chunks/app/
60+
state-name: .ftp-deploy-sync-state.json
4761

4862
- name: Deploy site files to FTP
4963
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')

0 commit comments

Comments
 (0)