Kopp_zokal
Kopp_zokal

Reputation: 33

Running simple exe into a docker container running microsoft/windowsservercore

I would like to run a simple application displaying a "Hello World" in a Docker container running under an images microsoft/windowsservercore.

-> I copy my executable into a container and then I commit my container to save the state. -> I launched my container and launched my executable.

Problem I have no output.

C:\>docker version
Client:
Version:      18.03.1-ce
API version:  1.37
Go version:   go1.9.5
Git commit:   9ee9f40
Built:        Thu Apr 26 07:12:48 2018
OS/Arch:      windows/amd64
Experimental: false
Orchestrator: swarm

Server:
 Engine:
  Version:      18.03.1-ce
  API version:  1.37 (minimum version 1.24)
  Go version:   go1.9.5
  Git commit:   9ee9f40
  Built:        Thu Apr 26 07:21:42 2018
  OS/Arch:      windows/amd64
 Experimental: false

Hello world code source

#include <iostream>

int main()
{
 std::cout << "Hello World " << "!\n";
}

The executable perfectly runs on a Windows machine.

Upvotes: 0

Views: 1663

Answers (1)

Hemant Singh
Hemant Singh

Reputation: 1608

The problem is that basic dlls are missing, you can refer: https://github.com/docker/for-win/issues/700

You can also try microsoft/aspnetcore.

Upvotes: 1

Related Questions