create-react-app/fullstack showing 'Hey, Node developers!'

Larry Marshall 21 Reputation points
2019-12-29T15:13:02.15+00:00

I have followed a couple of threads about deploying a cra app. None have worked. Any change I've made displays the 'Hey, Node developers!' page.

I ran 'npm run build' and ftp-ed the static folder to /site/wwwroot/. I also tried the following file, web.config, in the wwwroot folder.

The structure of the project is

build/
package.json
public/
server/
sql/
src/
I started the project with create-react-app and added an a Node Express server at the server directory. The server is proxied via the proxy key in package.json

Both the src and server folders contain index.js files. Each index.js file starts on its own unique port. The server makes SQL calls to an MSSQL database. I have managed to sync the in-house db to the Azure DB.

Any ideas on what I might try?

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

2 answers

Sort by: Most helpful
  1. Ryan Hill 26,146 Reputation points Microsoft Employee
    2019-12-30T19:23:12.497+00:00

    Hi @Larry Marshall make sure you've configured your npm start command under Configuration - General Settings. Let me know if this doesn't help.

    alt text

    1 person found this answer helpful.
    0 comments No comments

  2. Michael Dimmitt 1 Reputation point
    2021-02-12T00:05:39.09+00:00

    You can check that you have uploaded the files correctly by installing the vscode plugin and then logging in you will be able to see the files that are on the server.

    This will confirm that the build file uploaded correctly.

    Now, go back to portal.azure.com

    Settings > General settings > Startup Command

    add the following to serve the index.html from the build file.

    pm2 serve /home/site/wwwroot/ --no-daemon --spa

    link:
    https://stackoverflow.com/a/61386411/5283424

    0 comments No comments