I am trying to run locally on Windows Desktop a micro service in Docker (Windows Desktop Docker) and my docker file content is as below:
FROM mcr.microsoft.com/dotnet/core/aspnet:3.0
WORKDIR /app
COPY . .
EXPOSE 80
ENTRYPOINT ["dotnet", "ScheduleService.dll"]
when i issue docker run command to expose port 8081:80 using the following command, the container exits automatically. the run command being issued on Powershell is as below:
docker run -d -p 8081:80 schedule
When i check the docker using docker ps -a
command i get the following output:
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
8d2869a886f9 schedule "dotnet ScheduleServ…" 7 seconds ago Exited (2147516561) 4 seconds ago gracious_joliot
f2c7e9b43b0b schedule "dotnet ScheduleServ…" 19 hours ago Exited (2147516561) 19 hours ago pedantic_cerf
It says Exited. can anyone help me on this.