Comments (11)
Had same kind of issue too.
In my case I have a dependency that is a symbolic link to another folder of the repo (it's a monorepo).
Root cause may be linked to the App service sandbox model : https://github.com/projectkudu/kudu/wiki/Azure-Web-App-sandbox#symbolic-link-creation
I did a quick and dirty workaround in my github action, just before the azure/webapps-deploy
step.
- name: HACK - copy symbolic link to directory (Azure & symbolic links...)
working-directory: ./backend
run: cp -Lr node_modules/dependency/symlinked node_modules/dependency/symlinked-COPY && rm node_modules/dependency/symlinked && mv node_modules/dependency/symlinked-COPY node_modules/dependency/symlinked
from webapps-deploy.
I do not know what the current situation here is but I wanted to add just another dirty fix to this thread.
you can run the action below just before azure/webapps-deploy, which also seems to do the trick for your symbolic links under "node_modules/.bin" folder.
- name: rebuild
run: npm rebuild
from webapps-deploy.
same issue here
from webapps-deploy.
@danechitoaie is the action passing successfully? Can you please send the workflow and detailed logs?
from webapps-deploy.
@aksm-ms Yes, the action was passing successfully. I've since then moved to Heroku so I can't reproduce or test this anymore but basically the build on GitHub actions side was fine and successful. Problem is that then the GH action was doing a ZIP of the files (node_modules included) and then transferring the zip to Azure and then unzipping them there. This operation messes with the "sym links - https://en.wikipedia.org/wiki/Symbolic_link". So on GitHub actions (before the ZIP process) the symbolic links from within node_modules/.bin
are OK, after transferring the ZIP to Azure and unzipping the file the symbolic links are broken.
See this answer from here https://askubuntu.com/a/1203934/606393 I think this could be the solution to this problem.
The ZIP format supports storing the symbolic link. To store symbolic links as such, you can use the --symlinks option.
I haven't tested this, but it's a good lead to start from.
from webapps-deploy.
@danechitoaie i understand the issue is with symlinks, i am trying to figure out if the action code is failing or failure is on app service platform side.
From your description of problem, it was unclear if the action passed/failed without proper logs.
Since action passes, looks like issue is at the backend APIs which we use, will look it and update.
Also, it would be great if you can share any workflow run related info to debug like link to your workflow run, downloaded logs, etc.
from webapps-deploy.
zip deploy is handled by backend ZIP deploy Kudu API. There is already an issue on Kudu repo tracking this - projectkudu/kudu#2946 .
Please follow up with symlinks related issues on Kudu repo since action is using the same for ZIP deploy.
from webapps-deploy.
Had same kind of issue too.
In my case I have a dependency that is a symbolic link to another folder of the repo (it's a monorepo).
Root cause may be linked to the App service sandbox model : https://github.com/projectkudu/kudu/wiki/Azure-Web-App-sandbox#symbolic-link-creation
I did a quick and dirty workaround in my github action, just before the
azure/webapps-deploy
step.- name: HACK - copy symbolic link to directory (Azure & symbolic links...) working-directory: ./backend run: cp -Lr node_modules/dependency/symlinked node_modules/dependency/symlinked-COPY && rm node_modules/dependency/symlinked && mv node_modules/dependency/symlinked-COPY node_modules/dependency/symlinked
Have you found any other solution since then? I'm facing the same problem with monorepo - my symlinks seem to be plain files with path to workspaces (but fail once node tries to import them)
from webapps-deploy.
npm install $(npm pack <folder> | tail -1)
https://stackoverflow.com/questions/21425980/npm-install-without-symlinks-option-not-working
from webapps-deploy.
I do not know what the current situation here is but I wanted to add just another dirty fix to this thread.
you can run the action below just before azure/webapps-deploy, which also seems to do the trick for your symbolic links under "node_modules/.bin" folder.
- name: rebuild
run: npm rebuild
I ran into this problem with my Azure DevOps pipeline. My quick and dirty solution was to add npm rebuild && ...
to the beginning of my npm start
command. There's probably a better way to deal with it, but I needed it done.
from webapps-deploy.
ths is still an issue
from webapps-deploy.
Related Issues (20)
- Problems releasing after upgrade to v3 HOT 4
- v3 faield to reboot webapp due to 401, but v2 is OK HOT 7
- Git Python Causes problems while creating directories HOT 2
- Allow to overwrite GitHub comment instead of creating a new one HOT 1
- Successful deployment reported despite error HOT 2
- Code is not updated in linux based Azure Functions using ZIP package deploy HOT 1
- v3 deployment does not work with clean:false HOT 13
- Not able to apply npm install flags HOT 1
- README doesn't have a v3 example or explanation of the differences HOT 4
- Add sample(s) for OIDC HOT 1
- Azure Web App deployment from .zip fails after successfully deploying the content HOT 2
- V3 using node.js 16 upgrade to node.js 20 seeing 16 is deprecated HOT 16
- Deploy to web app does not working for .NET 8 and Linux based deployment - azure/webapps-deploy@v3 HOT 4
- Microsoft Azure Build and deploy PHP app to Azure Web App: Laravel App - Unable to create lockable file HOT 2
- Deployment Faile***, Error: Resource azwb********-tot doesn't exist. HOT 5
- The new option Clean should have defaulted to false or been highlighted as a breaking change HOT 4
- Azure Web Application not updated, action still claims "Success" HOT 9
- Can't deploy to ACA-based Function App
- Cann't show submit messages, ONLY show OneDeploy
- Parameter ''using: node20' is not supported, use 'docker', 'node12' or 'node16' instead.'
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from webapps-deploy.