Troubleshooting Bring Back SSH for App Service (Blessed) Images

1 minute read | By Keegan D'Souza

Overview

The blog will show you how to bring back the SSH feature on App Service (Blessed) Images. By default these commands will bring up the default parking page, as shown below, and make the SSH feature available.

Parking Page

This blog is not written for custom docker images running on app services. Refer to the following blogs if you are using a custom image.

Commands

Navigate to your app service on the Azure Portal then click on

Configuration -> General Settings -> Startup Command

Startup Command

Enter the below command dependant on your language stack and save your changes.

Make sure to remove or replace this command when you are done troubleshooting, otherwise your app service will continue to serve the default parking page.

Dot Net

dotnet /defaulthome/hostingstart/hostingstart.dll

Node

node /opt/startup/default-static-site.js

Python

gunicorn application:app --timeout 600 --access-logfile '-' --error-logfile '-' -c /opt/startup/gunicorn.conf.py --chdir=/opt/defaultsite

Java (SE)

java -jar -Dserver.port=80 /usr/local/appservice/parkingpage.jar

Go

/opt/startup/hostingstart

Reasoning and Use Cases

Sometimes deployment or startup issues can be tricky to troubleshoot on linux app services. If your container is crashing after a deployment you will not have access to this feature. This is because the SSH process is started on the app container itself.

Application Error SSH connection failure

With SSH working you can navigate the application containers file system to see what files are present and experiment with different startup commands to validate they are working successfully. If your container is not crashing, this feature should be working by default without modifying the startup command.

SSH connection success