I am trying to deploy a Node app on an Azure App Service, using Github and Kudu, running on Windows. The deployment works and the app is started.
My codebase is organised as follows:
/config
/res
/src
package.json
and package.json
contains node src/start.js
.
The problem I am having is that it seems that on that deployment the root directory for the Node app is site/wwwroot/src
and not (as on my local machine, or my previous deployment on AWS) site/wwwroot
. This leads to my code not finding the files inside /config
or /res
since the paths used in the code presume that the root is top level, and not inside /src
(e.g. ./res/myFile.jpg
will try opening site/wwwroot/src/res/myFile.jpg
and not site/wwwroot/res/myFile.jpg
).
I have been looking around but can't find how to change this. Can anyone help me?
Thanks!