@@ -2,36 +2,33 @@ name: Continuous Deployment
22
33on :
44 push :
5- branches : [ main ]
5+ branches : [main]
66
77jobs :
88 deploy :
9-
109 runs-on : ubuntu-latest
1110
1211 strategy :
1312 matrix :
1413 node-version : [16.x]
1514
1615 steps :
17- - uses : actions/checkout@v3
18- - name : Use Node.js ${{ matrix.node-version }}
19- uses : actions/setup-node@v3
20- with :
21- node-version : ${{ matrix.node-version }}
22- cache : ' npm'
23- - name : Cache
24- uses : actions/cache@v3.0.2
25- with :
26- path : frontend/node_modules
27- key : ${{ runner.os }}-${{ hashFiles('frontend/package-lock.json') }}
28- - run : cd frontend && npm ci && npm run build
29- - name : FTP Deploy
30- uses : SamKirkland/FTP-Deploy-Action@4.3.0
31- with :
32- server : ${{ secrets.ftp_server }}
33- username : ${{ secrets.ftp_username }}
34- password : ${{ secrets.ftp_password }}
35-
36-
37-
16+ - uses : actions/checkout@v3
17+ - name : Use Node.js ${{ matrix.node-version }}
18+ uses : actions/setup-node@v3
19+ with :
20+ node-version : ${{ matrix.node-version }}
21+ cache : " npm"
22+ - name : Cache
23+ uses : actions/cache@v3.0.2
24+ with :
25+ path : frontend/node_modules
26+ key : ${{ runner.os }}-${{ hashFiles('frontend/package-lock.json') }}
27+ - run : node frontend/tools/prod_change.js
28+ - run : cd frontend && npm ci && npm run build
29+ - name : FTP Deploy
30+ uses : SamKirkland/FTP-Deploy-Action@4.3.0
31+ with :
32+ server : ${{ secrets.ftp_server }}
33+ username : ${{ secrets.ftp_username }}
34+ password : ${{ secrets.ftp_password }}
0 commit comments