There are over 10,000 files in this artifact, consider creating an archive before upload to improve the upload performance.
I had this issue deploying a node app to Azure App Services.
I fixed it by adding a zip and an unzip step.
zip step is
- name: Zip artifact for deployment
run: zip release.zip ./* -r
unzip step is
- name: unzip artifact for deployment
run: unzip release.zip
Add the zip step after the build step and before Upload artifact step like this
- name: npm install, build, and test
run: |
npm install
npm run build --if-present
npm run test --if-present
- name: Zip artifact for deployment
run: zip release.zip ./* -r
- name: Upload artifact for deployment job
uses: actions/upload-artifact@v2
with:
name: node-app
path: release.zip
Then the unzip step is added after the download artifact step and before the deploy step like this.
steps:
- name: Download artifact from build job
uses: actions/download-artifact@v2
with:
name: node-app
- name: unzip artifact for deployment
run: unzip release.zip
- name: 'Deploy to Azure Web App'
id: deploy-to-webapp
uses: azure/webapps-deploy@v2
with:
I also faced this issue when deploying a react based app to Azure App service.
To add to the answer written by @steve, If the App service instance is windows based, one can use Powershell's Compress-Archive.
In build steps - zipping
Compress-Archive . release.zip
In deploy steps - unzipping
Expand-Archive release.zip
or
unzip release.zip
if the deployment script is using bash
You can zip all the files using below command and then upload the zip folder as your artifacts.
zip artifact.zip <generated_files>/*