Coder Social home page Coder Social logo

Comments (19)

NCarlsonMSFT avatar NCarlsonMSFT commented on June 5, 2024

This is a known-issue in docker: moby/moby#24348
The work-around is to change the casing of the Dockerfile.debug file to Dockerfile.Debug in the project and then rebuild the project.

from dockertoolsdocs.

mikehole avatar mikehole commented on June 5, 2024

Ok this got me somewhere and the image does appear to be building ok. The next problem is that debugging doesn't appear to be working:

D:\Source\Play\CoreWebApplicationDockerTest\src\CoreWebApplicationDockerTest\DockerTask.ps1 -Run -Environment Debug -Machine '' -RemoteDebugging $True -OpenSite $False
VERBOSE: Setting: $env:CLRDBG_VERSION = "VS2015U2"
VERBOSE: Setting: $env:REMOTE_DEBUGGING = 1
VERBOSE: Executing: docker-compose -f
'D:\Source\Play\CoreWebApplicationDockerTest\src\CoreWebApplicationDockerTest\bin\Docker\Debug\app\docker-compose.Debug
.yml' -p corewebapplicationdockertest up -d
Creating corewebapplicationdockertest_corewebapplicationdockertest_1

Run : Failed to start the container(s)
ERROR: for corewebapplicationdockertest driver failed programming external connectivity on endpoint corewebapplicationdockertest_corewebapplicationdockertest_1 (67b03b0e871d37052c211a55831e648f2c52291247831cc6f734fcc021d4ce46): Error starting userland proxy: write /port/tcp:0.0.0.0:80:tcp:172.18.0.2:80/ctl: errno 526
At D:\Source\Play\CoreWebApplicationDockerTest\src\CoreWebApplicationDockerTest\DockerTask.ps1:507 char:5
Encountered errors while bringing up the project.

  • Run
    
  • ~~~
    
    • CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException
    • FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Run

from dockertoolsdocs.

NCarlsonMSFT avatar NCarlsonMSFT commented on June 5, 2024

You don't appear to be getting to the debugger, the container is not starting. Do you have anything else using port 80 on the host? Are you spinning up more than one container in your compose file?

from dockertoolsdocs.

mikehole avatar mikehole commented on June 5, 2024

I have removed all images and containers from the Docker instance so nothing should be getting in the way. The project is an out of the box "File/New Project" project with the only change being that the Dockerfile.debug has been renames Dockerfile.Debug.

After the attempt to debug the container the image is created:

PS C:\Users\mike> docker images
REPOSITORY TAG IMAGE ID CREATED SIZE
username/webapplicationdockertest2 Debug 054d35cc5442 45 seconds ago 433.1 MB
username/webapplicationdockertest2 Debug-2016-07-19_08-27-54 054d35cc5442 45 seconds ago 433.1 MB
microsoft/dotnet 1.0.0-core 6b8beb20bfb6 12 hours ago 253.2 MB
PS C:\Users\mike>

But the container refuses to start.

from dockertoolsdocs.

mikehole avatar mikehole commented on June 5, 2024

Here is the complete build output (if it helps):

1>------ Build started: Project: WebApplicationDockerTest2, Configuration: Debug Any CPU ------
1> C:\Program Files\dotnet\dotnet.exe build "D:\Users\MikeHole\Documents\Visual Studio 2015\Projects\WebApplicationDockerTest2\src\WebApplicationDockerTest2" --configuration Debug --no-dependencies
1> Project WebApplicationDockerTest2 (.NETCoreApp,Version=v1.0) was previously compiled. Skipping compilation.
1> powershell -NonInteractive -ExecutionPolicy RemoteSigned .\DockerTask.ps1 -Build -Environment Debug -Machine '' -ClrDebugVersion VS2015U2
1> VERBOSE: Setting: $env:CLRDBG_VERSION = "VS2015U2"
1> VERBOSE: Setting: $env:REMOTE_DEBUGGING = 0
1> Publishing WebApplicationDockerTest2 for .NETCoreApp,Version=v1.0
1> Bundling with configuration from D:\Users\MikeHole\Documents\Visual Studio 2015\Projects\WebApplicationDockerTest2\src\WebApplicationDockerTest2\bundleconfig.json
1> Processing wwwroot/css/site.min.css
1> Bundled
1> Minified
1> Processing wwwroot/js/site.min.js
1> Project WebApplicationDockerTest2 (.NETCoreApp,Version=v1.0) was previously compiled. Skipping compilation.
1> Configuring the following project for use with IIS: 'D:\Users\MikeHole\Documents\Visual Studio 2015\Projects\WebApplicationDockerTest2\src\WebApplicationDockerTest2\bin\Docker\Debug\app'
1> Updating web.config at 'D:\Users\MikeHole\Documents\Visual Studio 2015\Projects\WebApplicationDockerTest2\src\WebApplicationDockerTest2\bin\Docker\Debug\app\web.config'
1> Configuring project completed successfully
1> publish: Published to D:\Users\MikeHole\Documents\Visual Studio 2015\Projects\WebApplicationDockerTest2\src\WebApplicationDockerTest2\bin\Docker\Debug\app
1> Published 1/1 projects successfully
1> Info: Using clrdbg version '14.0.25430-preview-3098923'
1> Info: Using Runtime ID 'debian.8-x64'
1>
1>
1> Directory: C:\Users\mike\AppData\Local\Temp
1>
1>
1> Mode LastWriteTime Length Name
1> ---- ------------- ------ ----
1> d----- 19/07/2016 08:26 7a54c4f5-922d-4c82-a462-9aad92a043e7
1> Info: Generating project.json
1> Info: Generating NuGet.config
1> Info: Executing dotnet restore
1> log : Restoring packages for C:\Users\mike\AppData\Local\Temp\7a54c4f5-922d-4c82-a462-9aad92a043e7\project.json...
1> log : Writing lock file to disk. Path: C:\Users\mike\AppData\Local\Temp\7a54c4f5-922d-4c82-a462-9aad92a043e7\project.lock.json
1> log : C:\Users\mike\AppData\Local\Temp\7a54c4f5-922d-4c82-a462-9aad92a043e7\project.json
1> log : Restore completed in 3360ms.
1> Info: Executing dotnet publish
1> Publishing 7a54c4f5-922d-4c82-a462-9aad92a043e7 for .NETCoreApp,Version=v1.0/debian.8-x64
1> publish: Published to D:\Users\MikeHole\Documents\Visual Studio 2015\Projects\WebApplicationDockerTest2\src\WebApplicationDockerTest2\bin\Docker\Debug\clrdbg
1> Published 1/1 projects successfully
1> Successfully installed clrdbg at 'D:\Users\MikeHole\Documents\Visual Studio 2015\Projects\WebApplicationDockerTest2\src\WebApplicationDockerTest2\bin\Docker\Debug\clrdbg'
1> VERBOSE: Executing: docker build -f 'D:\Users\MikeHole\Documents\Visual Studio
1> 2015\Projects\WebApplicationDockerTest2\src\WebApplicationDockerTest2\bin\Docker\Debug\app\Dockerfile.Debug' -t
1> username/webapplicationdockertest2:Debug 'D:\Users\MikeHole\Documents\Visual Studio
1> 2015\Projects\WebApplicationDockerTest2\src\WebApplicationDockerTest2\bin\Docker\Debug'
1> Sending build context to Docker daemon 557.1 kB
1> Sending build context to Docker daemon 1.114 MB
1> Sending build context to Docker daemon 1.671 MB
1> Sending build context to Docker daemon 2.228 MB
1> Sending build context to Docker daemon 2.785 MB
1> Sending build context to Docker daemon 3.342 MB
1> Sending build context to Docker daemon 3.899 MB
1> Sending build context to Docker daemon 4.456 MB
1> Sending build context to Docker daemon 5.014 MB
1> Sending build context to Docker daemon 5.571 MB
1> Sending build context to Docker daemon 6.128 MB
1> Sending build context to Docker daemon 6.685 MB
1> Sending build context to Docker daemon 7.242 MB
1> Sending build context to Docker daemon 7.799 MB
1> Sending build context to Docker daemon 8.356 MB
1> Sending build context to Docker daemon 8.913 MB
1> Sending build context to Docker daemon 9.47 MB
1> Sending build context to Docker daemon 10.03 MB
1> Sending build context to Docker daemon 10.58 MB
1> Sending build context to Docker daemon 11.14 MB
1> Sending build context to Docker daemon 11.7 MB
1> Sending build context to Docker daemon 12.26 MB
1> Sending build context to Docker daemon 12.81 MB
1> Sending build context to Docker daemon 13.37 MB
1> Sending build context to Docker daemon 13.93 MB
1> Sending build context to Docker daemon 14.48 MB
1> Sending build context to Docker daemon 15.04 MB
1> Sending build context to Docker daemon 15.6 MB
1> Sending build context to Docker daemon 16.15 MB
1> Sending build context to Docker daemon 16.71 MB
1> Sending build context to Docker daemon 17.27 MB
1> Sending build context to Docker daemon 17.83 MB
1> Sending build context to Docker daemon 18.38 MB
1> Sending build context to Docker daemon 18.94 MB
1> Sending build context to Docker daemon 19.5 MB
1> Sending build context to Docker daemon 20.05 MB
1> Sending build context to Docker daemon 20.61 MB
1> Sending build context to Docker daemon 21.17 MB
1> Sending build context to Docker daemon 21.73 MB
1> Sending build context to Docker daemon 22.28 MB
1> Sending build context to Docker daemon 22.84 MB
1> Sending build context to Docker daemon 23.4 MB
1> Sending build context to Docker daemon 23.95 MB
1> Sending build context to Docker daemon 24.51 MB
1> Sending build context to Docker daemon 25.07 MB
1> Sending build context to Docker daemon 25.62 MB
1> Sending build context to Docker daemon 26.18 MB
1> Sending build context to Docker daemon 26.74 MB
1> Sending build context to Docker daemon 27.3 MB
1> Sending build context to Docker daemon 27.85 MB
1> Sending build context to Docker daemon 28.41 MB
1> Sending build context to Docker daemon 28.97 MB
1> Sending build context to Docker daemon 29.52 MB
1> Sending build context to Docker daemon 30.08 MB
1> Sending build context to Docker daemon 30.64 MB
1> Sending build context to Docker daemon 31.2 MB
1> Sending build context to Docker daemon 31.75 MB
1> Sending build context to Docker daemon 32.31 MB
1> Sending build context to Docker daemon 32.87 MB
1> Sending build context to Docker daemon 33.42 MB
1> Sending build context to Docker daemon 33.98 MB
1> Sending build context to Docker daemon 34.54 MB
1> Sending build context to Docker daemon 35.09 MB
1> Sending build context to Docker daemon 35.65 MB
1> Sending build context to Docker daemon 36.21 MB
1> Sending build context to Docker daemon 36.77 MB
1> Sending build context to Docker daemon 37.32 MB
1> Sending build context to Docker daemon 37.88 MB
1> Sending build context to Docker daemon 38.44 MB
1> Sending build context to Docker daemon 38.99 MB
1> Sending build context to Docker daemon 39.55 MB
1> Sending build context to Docker daemon 40.11 MB
1> Sending build context to Docker daemon 40.67 MB
1> Sending build context to Docker daemon 41.22 MB
1> Sending build context to Docker daemon 41.78 MB
1> Sending build context to Docker daemon 42.34 MB
1> Sending build context to Docker daemon 42.89 MB
1> Sending build context to Docker daemon 43.45 MB
1> Sending build context to Docker daemon 44.01 MB
1> Sending build context to Docker daemon 44.56 MB
1> Sending build context to Docker daemon 45.12 MB
1> Sending build context to Docker daemon 45.68 MB
1> Sending build context to Docker daemon 46.24 MB
1> Sending build context to Docker daemon 46.79 MB
1> Sending build context to Docker daemon 47.35 MB
1> Sending build context to Docker daemon 47.91 MB
1> Sending build context to Docker daemon 48.46 MB
1> Sending build context to Docker daemon 49.02 MB
1> Sending build context to Docker daemon 49.58 MB
1> Sending build context to Docker daemon 50.14 MB
1> Sending build context to Docker daemon 50.69 MB
1> Sending build context to Docker daemon 51.25 MB
1> Sending build context to Docker daemon 51.81 MB
1> Sending build context to Docker daemon 52.36 MB
1> Sending build context to Docker daemon 52.92 MB
1> Sending build context to Docker daemon 53.48 MB
1> Sending build context to Docker daemon 54.03 MB
1> Sending build context to Docker daemon 54.59 MB
1> Sending build context to Docker daemon 55.15 MB
1> Sending build context to Docker daemon 55.71 MB
1> Sending build context to Docker daemon 56.26 MB
1> Sending build context to Docker daemon 56.82 MB
1> Sending build context to Docker daemon 57.38 MB
1> Sending build context to Docker daemon 57.93 MB
1> Sending build context to Docker daemon 58.49 MB
1> Sending build context to Docker daemon 59.05 MB
1> Sending build context to Docker daemon 59.6 MB
1> Sending build context to Docker daemon 60.16 MB
1> Sending build context to Docker daemon 60.72 MB
1> Sending build context to Docker daemon 61.28 MB
1> Sending build context to Docker daemon 61.83 MB
1> Sending build context to Docker daemon 62.39 MB
1> Sending build context to Docker daemon 62.95 MB
1> Sending build context to Docker daemon 63.5 MB
1> Sending build context to Docker daemon 64.06 MB
1> Sending build context to Docker daemon 64.62 MB
1> Sending build context to Docker daemon 65.18 MB
1> Sending build context to Docker daemon 65.73 MB
1> Sending build context to Docker daemon 66.29 MB
1> Sending build context to Docker daemon 66.85 MB
1> Sending build context to Docker daemon 67.4 MB
1> Sending build context to Docker daemon 67.96 MB
1> Sending build context to Docker daemon 68.52 MB
1> Sending build context to Docker daemon 69.07 MB
1> Sending build context to Docker daemon 69.63 MB
1> Sending build context to Docker daemon 70.19 MB
1> Sending build context to Docker daemon 70.75 MB
1> Sending build context to Docker daemon 71.3 MB
1> Sending build context to Docker daemon 71.86 MB
1> Sending build context to Docker daemon 72.42 MB
1> Sending build context to Docker daemon 72.97 MB
1> Sending build context to Docker daemon 73.53 MB
1> Sending build context to Docker daemon 74.09 MB
1> Sending build context to Docker daemon 74.65 MB
1> Sending build context to Docker daemon 75.2 MB
1> Sending build context to Docker daemon 75.76 MB
1> Sending build context to Docker daemon 76.32 MB
1> Sending build context to Docker daemon 76.87 MB
1> Sending build context to Docker daemon 77.43 MB
1> Sending build context to Docker daemon 77.99 MB
1> Sending build context to Docker daemon 78.54 MB
1> Sending build context to Docker daemon 79.1 MB
1> Sending build context to Docker daemon 79.66 MB
1> Sending build context to Docker daemon 80.22 MB
1> Sending build context to Docker daemon 80.77 MB
1> Sending build context to Docker daemon 81.33 MB
1> Sending build context to Docker daemon 81.89 MB
1> Sending build context to Docker daemon 82.44 MB
1> Sending build context to Docker daemon 83 MB
1> Sending build context to Docker daemon 83.56 MB
1> Sending build context to Docker daemon 84.12 MB
1> Sending build context to Docker daemon 84.67 MB
1> Sending build context to Docker daemon 85.23 MB
1> Sending build context to Docker daemon 85.79 MB
1> Sending build context to Docker daemon 86.34 MB
1> Sending build context to Docker daemon 86.9 MB
1> Sending build context to Docker daemon 87.46 MB
1> Sending build context to Docker daemon 88.01 MB
1> Sending build context to Docker daemon 88.57 MB
1> Sending build context to Docker daemon 89.13 MB
1> Sending build context to Docker daemon 89.69 MB
1> Sending build context to Docker daemon 90.24 MB
1> Sending build context to Docker daemon 90.8 MB
1> Sending build context to Docker daemon 91.36 MB
1> Sending build context to Docker daemon 91.91 MB
1> Sending build context to Docker daemon 92.47 MB
1> Sending build context to Docker daemon 93.03 MB
1> Sending build context to Docker daemon 93.59 MB
1> Sending build context to Docker daemon 94.14 MB
1> Sending build context to Docker daemon 94.7 MB
1> Sending build context to Docker daemon 94.92 MB
1>
1> Step 1 : FROM microsoft/dotnet:1.0.0-core
1> 1.0.0-core: Pulling from microsoft/dotnet
1> 5c90d4a2d1a8: Pulling fs layer
1> 299ba482cef3: Pulling fs layer
1> 03446caf125a: Pulling fs layer
1> 482fe8722f38: Pulling fs layer
1> 482fe8722f38: Waiting
1> 03446caf125a: Verifying Checksum
1> 03446caf125a: Download complete
1> 299ba482cef3: Verifying Checksum
1> 299ba482cef3: Download complete
1> 482fe8722f38: Verifying Checksum
1> 482fe8722f38: Download complete
1> 5c90d4a2d1a8: Verifying Checksum
1> 5c90d4a2d1a8: Download complete
1> 5c90d4a2d1a8: Pull complete
1> 299ba482cef3: Pull complete
1> 03446caf125a: Pull complete
1> 482fe8722f38: Pull complete
1> Digest: sha256:ba9a1b2920a8f662f18936bfbe293168462cac37fcb81c60c2af7c1fbf5a6a20
1> Status: Downloaded newer image for microsoft/dotnet:1.0.0-core
1> ---> 6b8beb20bfb6
1> Step 2 : WORKDIR /app
1> ---> Running in d15803499bfb
1> ---> afb0719157f4
1> Removing intermediate container d15803499bfb
1> Step 3 : ENV ASPNETCORE_URLS http://*:80
1> ---> Running in 975d684cddd0
1> ---> ea4a5541b457
1> Removing intermediate container 975d684cddd0
1> Step 4 : EXPOSE 80
1> ---> Running in 230b1247e864
1> ---> c3401556c031
1> Removing intermediate container 230b1247e864
1> Step 5 : COPY /clrdbg /clrdbg
1> ---> 236f23b6f07e
1> Removing intermediate container 36c8f9d8892c
1> Step 6 : RUN chmod 700 -R /clrdbg
1> ---> Running in d2c110bd318d
1> ---> 297a8944ea84
1> Removing intermediate container d2c110bd318d
1> Step 7 : COPY /app /app
1> ---> 028ff45b636d
1> Removing intermediate container 9b602d700225
1> Step 8 : ENTRYPOINT /bin/bash -c if [ "$REMOTE_DEBUGGING" -eq 0 ]; then dotnet WebApplicationDockerTest2.dll; else sleep infinity; fi
1> ---> Running in c7a2874c58f9
1> ---> 054d35cc5442
1> Removing intermediate container c7a2874c58f9
1> Successfully built 054d35cc5442
1>EXEC : SECURITY warning : You are building a Docker image from Windows against a non-Windows Docker host. All files and directories added to build context will have '-rwxr-xr-x' permissions. It is recommended to double check and reset permissions for sensitive files and directories.
1> VERBOSE: Executing: docker tag username/webapplicationdockertest2:Debug
1> username/webapplicationdockertest2:Debug-2016-07-19_08-27-54
1>
1>
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========

from dockertoolsdocs.

NCarlsonMSFT avatar NCarlsonMSFT commented on June 5, 2024

More helpful would be the output from the Docker pane and/or Debugging pane. But you still haven't answered my questions: Do you have anything else using port 80 on the host (even if it isn't a container)? Are you spinning up more than one container in your compose file?
Also, you appear to be using the Docker for Windows beta. Looking on Bing I'm noticing several other users reporting this issue (for instance: https://forums.docker.com/t/cannot-bind-por-80-or-443-windows/18355) so you may be running into a platform issue. As a temporary work around consider using a different port as several users report that working.

from dockertoolsdocs.

mikehole avatar mikehole commented on June 5, 2024

I have IIS on the host machine this I have tried stopping it, no success. I mentioned the project is as a new project to point out that the compose file is unchanged and no other containers are being created.

But you are right it's the ports issue. I change the docker-compose.debug.yaml to:

version: '2'

services:
webapplicationdockertest2:
image: username/webapplicationdockertest2:Debug
environment:
- REMOTE_DEBUGGING=${REMOTE_DEBUGGING}
ports:
- "8080:80"
volumes:
- .:/app

And it's up and running and debugging as expected 💯. Thanks for your help!

For anybody else reading this the change is:
"8080:80"
From:
"80:80"

from dockertoolsdocs.

saurabhsoni86 avatar saurabhsoni86 commented on June 5, 2024

Hi All,

I am having the issue with Docker in my asp.net Core application in VS 2015 the error is,

Error Running: powershell -NonInteractive -ExecutionPolicy RemoteSigned .\DockerTask.ps1 -Build -Environment Debug -Machine '' -ClrDebugVersion VS2015U2. See the output window for details.

the Logs are ,

1>------ Rebuild All started: Project: TesApp.Docker, Configuration: Debug Any CPU ------
1> powershell -NonInteractive -ExecutionPolicy RemoteSigned .\DockerTask.ps1 -Clean -Environment Debug -Machine ''
1> VERBOSE: Setting: $env:CLRDBG_VERSION = "VS2015U2"
1> VERBOSE: Setting: $env:REMOTE_DEBUGGING = 0
1> VERBOSE: Executing: docker-compose -f
1> 'C:\Users\Desktop\TesApp\TesApp.Docker\src\TesApp.Docker\docker-compose.debug.yml' -p
1> TesAppdocker down
1> 'docker-compose' is not recognized as an internal or external command,
1> operable program or batch file.
1> Clean : Failed to clean up the containers
1> At C:\Users\Desktop\TesApp\TesApp.Docker\src\TesApp.Docker\DockerTask.ps1:467 char:5
1> + Clean
1> + ~~~~~
1> + CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException
1> + FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Clean
1>
1>C:\Users\Desktop\TesApp\TesApp.Docker\src\TesApp.Docker\Properties\Docker.targets(61,5): error MSB3073: The command "powershell -NonInteractive -ExecutionPolicy RemoteSigned .\DockerTask.ps1 -Clean -Environment Debug -Machine ''" exited with code 1.
1>C:\Users\Desktop\TesApp\TesApp.Docker\src\TesApp.Docker\DockerTask.ps1 : error : Error Running: powershell -NonInteractive -ExecutionPolicy RemoteSigned .\DockerTask.ps1 -Clean -Environment Debug -Machine ''. See the output window for details.
========== Rebuild All: 0 succeeded, 1 failed, 0 skipped ==========

Can you please help me with the issue resolution

from dockertoolsdocs.

dbreshears avatar dbreshears commented on June 5, 2024

Do you have Docker For Windows or Docker Toolbox installed? https://docs.docker.com/engine/installation/windows/

from dockertoolsdocs.

saurabhsoni86 avatar saurabhsoni86 commented on June 5, 2024

@dbreshears : No, I haven't installed it yet. Is it required?

from dockertoolsdocs.

dbreshears avatar dbreshears commented on June 5, 2024

@saurabhsoni86 : Yes. If using our Visual Studio extension you will need one or the other. I would recommend Docker for Windows as we default to that experience now. Please the see the pre-reqs at https://visualstudiogallery.msdn.microsoft.com/0f5b2caa-ea00-41c8-b8a2-058c7da0b3e4

from dockertoolsdocs.

saurabhsoni86 avatar saurabhsoni86 commented on June 5, 2024

@dbreshears : I have installed the VS Extension for Docker and trying to build my project but same error is given.

from dockertoolsdocs.

NCarlsonMSFT avatar NCarlsonMSFT commented on June 5, 2024

Have you installed: https://www.docker.com/products/docker#/windows ?

from dockertoolsdocs.

saurabhsoni86 avatar saurabhsoni86 commented on June 5, 2024

@NCarlsonMSFT : Yes, The same one I have installed.

from dockertoolsdocs.

NCarlsonMSFT avatar NCarlsonMSFT commented on June 5, 2024

The error message: 'docker-compose' is not recognized as an internal or external command, operable program or batch file. suggests that docker-compose is not installed or is at least not on %PATH%. Can you use docker-compose from a command prompt? Can you see it installed in "C:\Program Files\Docker\Docker\Resources\bin\docker-compose.exe"?

from dockertoolsdocs.

saurabhsoni86 avatar saurabhsoni86 commented on June 5, 2024

@NCarlsonMSFT: I am able to install Docker for windows now. I am managed for docker build now and I have also created the Docker Image. Now the thing is When I write command in proershell "docker run -t -p 5000:5000 6cd839a046ae". (here 6cd839a046ae is the Image ID) and if I check localhost:5000 on browser, I am not able to execute website.
Can you please help me with how do I run docker Image and also If I want to create Powershell script for the same. Please help me with that too.

from dockertoolsdocs.

NCarlsonMSFT avatar NCarlsonMSFT commented on June 5, 2024

How did you create the image? Images created by our tools listen to port 80 by default so you should use 80:80 instead of 5000:5000. As far as using a PowerShell script goes both our tools for VS and VS Code will generate one for you with the dockerfile and compose files. If you Call Get-Help on the script it will describe it's usage.

from dockertoolsdocs.

saurabhsoni86 avatar saurabhsoni86 commented on June 5, 2024

I have created one simple application in asp.net core on my local Windows machine.
I have Linux(Centos) VM where I have installed Docker and dotnet core.
Now I want to create docker image on linux vm.
Can you please help me or provide some steps how do I create docker Image?

from dockertoolsdocs.

NCarlsonMSFT avatar NCarlsonMSFT commented on June 5, 2024

I'm still not sure what tool-chain you are using, but here are some options for you:

If you just want tooling to generate scripts to help you, you can use: aka.ms/yodocker on windows or directly in the Linux VM (the tool also generates JSON files for integrating with VSCode)

If you want to use Visual Studio then you can use http://aka.ms/dockertoolsforvs, but you will need to register your Linux VM with docker-machine on your windows machine (https://docs.docker.com/machine/drivers/generic/)

If you just want to use make your own dockerfile and use the docker cli directly see https://hub.docker.com/r/microsoft/dotnet/ for recommended base images and getting started info.

from dockertoolsdocs.

Related Issues (6)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.