Angular app + github action azure/webapps-deploy@v1 problem

Thomas 96 Reputation points
2020-03-22T23:54:13.007+00:00

Hi,

when I use the github action azure/webapps-deploy@v1 to deploy to a node12 app service the webapp files get pushed to /home/sites/wwwroot .
The webserver pm2 however seems to host another directory:

cat /opt/startup/default-static-site.js
var express = require('express');
var server = express();
var options = {
index: ['index.html','hostingstart.html']
};
server.use('/', express.static('/opt/startup', options));
server.listen(process.env.PORT);

since my files are not in this directory I am only getting the getting started page
I can fix this manually by

/home/site/wwwroot# cp -R ./* /opt/startup

but this does not seem right.

Is there a way for me to influence which directory is hosted by pm2 or where the github action deploys my files to?

regards Thomas

Azure App Service
Azure App Service
Azure App Service is a service used to create and deploy scalable, mission-critical web apps.
6,925 questions
0 comments No comments
{count} votes

0 additional answers

Sort by: Most helpful