echo "Building dispatchermanager Docker Image"; dotnet clean $paths = 'LCU.WebApps.Internal.DispatcherManager/bin', 'LCU.WebApps.Internal.DispatcherManager/obj' foreach ($path in $paths) { if (Test-Path -LiteralPath $path) { rm $path -r -force } else { "Path doesn't exist: $path" } } docker build -t landmarkcu/temenos-dictionary-manager . echo "Adding self-singed certificate for HTTPS" dotnet dev-certs https --clean dotnet dev-certs https -ep ".\.aspnet\https\aspnetapp.pfx" -p testcert dotnet dev-certs https --trust echo "Running dispatchermanager Docker Container"; docker run --rm -it -p 7285:80 ` -p 7284:443 ` -e ASPNETCORE_URLS="https://+;http://+" ` -e ASPNETCORE_HTTPS_PORT=7284 ` -e ASPNETCORE_Kestrel__Certificates__Default__Password=testcert ` -e ASPNETCORE_Kestrel__Certificates__Default__Path=/https/aspnetapp.pfx ` --mount type=bind,src="$(PWD)\.aspnet\https",target=/https/ landmarkcu/dispatcher-manager rm -r -fo ".\.aspnet"