Skip to content

Images with Docker over HTTPS: Update port defaults, Incorrect sample commands #34061

@bzuidgeest

Description

@bzuidgeest

Description

docker pull mcr.microsoft.com/dotnet/samples:aspnetapp
docker run --rm -it -p 8000:80 -p 8001:443 -e ASPNETCORE_URLS="https://+;http://+" -e ASPNETCORE_HTTPS_PORTS=8001 -e ASPNETCORE_Kestrel__Certificates__Default__Password="<CREDENTIAL_PLACEHOLDER>" -e ASPNETCORE_Kestrel__Certificates__Default__Path=c:\https\aspnetapp.pfx -v %USERPROFILE%.aspnet\https:C:\https\ --user ContainerAdministrator mcr.microsoft.com/dotnet/samples:aspnetapp

the internal https port in this example is 443, so shouldn't it be ASPNETCORE_HTTPS_PORTS=443?
Also the new defaults are port 8080 and 8081, no longer 80 and 443.

Page URL

https://learn.microsoft.com/en-us/aspnet/core/security/docker-https?view=aspnetcore-8.0

Content source URL

https://github.com/dotnet/AspNetCore.Docs/blob/main/aspnetcore/security/docker-https.md

Document ID

2f32c7c3-8667-0e88-495b-c0c888572964

Article author

@Rick-Anderson

Metadata

Metadata

Assignees

Labels

Pri1doc-out-of-dateDoc is out of date with the current version

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions