Just to highlight, on Azure App service, you can configure your app to start with PM2, or with NPM, or with a custom command.
I’m not sure if you’re using built-in image or custom container - In order for a custom container to support SSH, you must add it into the Dockerfile itself.
You may try the following steps to isolate the issue:
To start your app using npm start, just make sure a start script is in the package.json file.
So, the container automatically starts your app with PM2 when one of the common Node.js files is found in your project.
You can also inspect the log files in a browser at https://<app-name>.scm.azurewebsites.net/api/logs/docker.
Use the EXPOSE instruction to open port 2222 in the container (Docker file: EXPOSE 80 2222)
In the start-up script for your container, start the SSH server. (/usr/sbin/sshd)
Also, you may try with --no-daemon is appended to your pm2 start npm.