Skip to content

Commit f55f587

Browse files
committed
fix(ci): switch to tar.gz artifact format to prevent extraction errors
1 parent ba35f06 commit f55f587

File tree

2 files changed

+15
-9
lines changed

2 files changed

+15
-9
lines changed

.github/workflows/cms_cms.yml

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,29 +47,32 @@ jobs:
4747
rm -rf .next/standalone/node_modules/@swc
4848
cp -rL node_modules/@swc .next/standalone/node_modules/
4949
cd .next/standalone
50-
zip -r ../../release.zip .
50+
tar -hczf ../../release.tar.gz .
5151
5252
- name: Upload artifact for deployment job
5353
uses: actions/upload-artifact@v4
5454
with:
5555
name: node-app
56-
path: release.zip
56+
path: release.tar.gz
5757

5858
deploy:
5959
runs-on: ubuntu-latest
6060
needs: build
61+
environment:
62+
name: "Production"
63+
url: ${{ steps.deploy-to-webapp.outputs.webapp-url }}
6164

6265
steps:
6366
- name: Download artifact from build job
6467
uses: actions/download-artifact@v4
6568
with:
6669
name: node-app
6770

68-
- name: "Deploy to Azure Web App"
71+
- name: Deploy to Azure Web App
6972
id: deploy-to-webapp
70-
uses: azure/webapps-deploy@v3
73+
uses: azure/webapps-deploy@v2.2.8
7174
with:
7275
app-name: "cms"
7376
slot-name: "Production"
74-
package: release.zip
77+
package: release.tar.gz
7578
publish-profile: ${{ secrets.AZUREAPPSERVICE_PUBLISHPROFILE_6CBFCF5F964D46BF9BBDEF30B4B76FE1 }}

.github/workflows/main_cms.yml

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -48,17 +48,20 @@ jobs:
4848
rm -rf .next/standalone/node_modules/@swc
4949
cp -rL node_modules/@swc .next/standalone/node_modules/
5050
cd .next/standalone
51-
zip -r ../../release.zip .
51+
tar -hczf ../../release.tar.gz .
5252
5353
- name: Upload artifact for deployment job
5454
uses: actions/upload-artifact@v4
5555
with:
5656
name: node-app
57-
path: release.zip
57+
path: release.tar.gz
5858

5959
deploy:
6060
runs-on: ubuntu-latest
6161
needs: build
62+
environment:
63+
name: "Production"
64+
url: ${{ steps.deploy-to-webapp.outputs.webapp-url }}
6265

6366
steps:
6467
- name: Download artifact from build job
@@ -68,9 +71,9 @@ jobs:
6871

6972
- name: "Deploy to Azure Web App"
7073
id: deploy-to-webapp
71-
uses: azure/webapps-deploy@v3
74+
uses: azure/webapps-deploy@v2.2.8
7275
with:
7376
app-name: "cms"
7477
slot-name: "Production"
75-
package: release.zip
78+
package: release.tar.gz
7679
publish-profile: ${{ secrets.AZUREAPPSERVICE_PUBLISHPROFILE_10465936071D4A7AA627DEB04C65156B }}

0 commit comments

Comments
 (0)