https://github.com/netlah/aspnet-webssh
Custom ASP.NET Core Runtime image supports Azure AppService Web SSH
https://github.com/netlah/aspnet-webssh
appservice aspnetcore azure ssh webssh
Last synced: 12 months ago
JSON representation
Custom ASP.NET Core Runtime image supports Azure AppService Web SSH
- Host: GitHub
- URL: https://github.com/netlah/aspnet-webssh
- Owner: NetLah
- License: mit
- Created: 2022-01-17T09:23:07.000Z (about 4 years ago)
- Default Branch: main
- Last Pushed: 2025-02-14T08:53:02.000Z (12 months ago)
- Last Synced: 2025-02-14T09:38:54.358Z (12 months ago)
- Topics: appservice, aspnetcore, azure, ssh, webssh
- Language: PowerShell
- Homepage: https://hub.docker.com/r/netlah/aspnet-webssh
- Size: 113 KB
- Stars: 1
- Watchers: 2
- Forks: 0
- Open Issues: 2
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# ASP.NET Core Runtime image supports Azure AppService Web SSH
A customized ASP.NET Core Runtime image supports Azure AppService Web SSH. Docker image repository is on https://hub.docker.com/r/netlah/aspnet-webssh.
## Support ASP.NET Core
- ASP.NET Core 6.0, mcr.microsoft.com/dotnet/aspnet:6.0 tags: `6.0-alpine`, `6.0-bookworm-slim`, `6.0-bullseye-slim`, `6.0-jammy`, `6.0-focal`
- ASP.NET Core 8.0, mcr.microsoft.com/dotnet/aspnet:8.0 tags: `8.0-alpine`, `8.0-bookworm-slim`, `8.0-noble`, `8.0-jammy`
- ASP.NET Core 9.0, mcr.microsoft.com/dotnet/aspnet:9.0 tags: `9.0-alpine`, `9.0-bookworm-slim`, `9.0-noble`
## Github source
https://github.com/NetLah/aspnet-webssh
## Build Status
[](https://github.com/NetLah/aspnet-webssh/actions/workflows/docker-image.yml)
## Run example ASP.NET Core container with WebSSH support
- Run with WebSSH support, using `STARTCOMMAND` environment for original entrypoint.
```
docker run -it --rm --name aspnetssh --entrypoint /opt/startup/init_container.sh -e "STARTUPCOMMAND=exec dotnet WebApp.dll" -p 5002:80 -p 2222:2222 -e TZ=Asia/Singapore netlah/spa-host:6.0-alpine
```
- Run with WebSSH support, using command arguments for original entrypoint.
```
docker run -it --rm --name aspnetssh --entrypoint /opt/startup/init_container.sh -p 5002:80 -p 2222:2222 -e TZ=Asia/Singapore netlah/spa-host:6.0-alpine exec dotnet WebApp.dll
```
Output
```
_ ___ ___ _ _ ___ _____ ___
/_\ / __| _ \| \| | __|_ _| / __|___ _ _ ___
/ _ \\__ \ _/| .` | _| | | | (__/ _ \ '_/ -_)
/_/ \_\___/_|(_)_|\_|___| |_| \___\___/_| \___|
Alpine Linux v3.16
ASP.NET Core v6.0.10
Startup 2022-10-05 12:34:56 +0800 Asia/Singapore
[02:33:30 INF] Application starting...
[02:33:30 INF] Application initializing...
```

## Test SSH to container

## Reference
- https://learn.microsoft.com/en-us/azure/app-service/configure-custom-container?pivots=container-linux#enable-ssh
- https://mcr.microsoft.com/en-us/product/dotnet/aspnet/tags