spurin / diveintoansible-lab

Dive Into Ansible Lab
788 stars 498 forks source link

Failed to execute script docker-compose #37

Closed jocaputo closed 3 years ago

jocaputo commented 3 years ago

Here my .env file:

sshd ports

UBUNTUC_PORT_SSHD=2221 UBUNTU1_PORT_SSHD=2222 UBUNTU2_PORT_SSHD=2223 UBUNTU3_PORT_SSHD=2224 CENTOS1_PORT_SSHD=2225 CENTOS2_PORT_SSHD=2226 CENTOS3_PORT_SSHD=2227

ttyd (web terminal) ports

UBUNTUC_PORT_TTYD=7681 UBUNTU1_PORT_TTYD=7682 UBUNTU2_PORT_TTYD=7683 UBUNTU3_PORT_TTYD=7684 CENTOS1_PORT_TTYD=7685 CENTOS2_PORT_TTYD=7686 CENTOS3_PORT_TTYD=7687

Shared config volume

CONFIG=/host_mnt/c/users/james/diveintoansible-lab/config

Shared home directories

ANSIBLE_HOME=/host_mnt/c/users/james/diveintoansible-lab/ansible_home

===================================================================================

And here is the output after running the docker-compose up command

$ docker-compose up Traceback (most recent call last): File "docker\api\client.py", line 214, in _retrieve_server_version File "docker\api\daemon.py", line 181, in version File "docker\utils\decorators.py", line 46, in inner File "docker\api\client.py", line 237, in _get File "requests\sessions.py", line 543, in get File "requests\sessions.py", line 530, in request File "requests\sessions.py", line 643, in send File "requests\adapters.py", line 439, in send File "urllib3\connectionpool.py", line 670, in urlopen File "urllib3\connectionpool.py", line 392, in _make_request File "http\client.py", line 1255, in request File "http\client.py", line 1301, in _send_request File "http\client.py", line 1250, in endheaders File "http\client.py", line 1010, in _send_output File "http\client.py", line 950, in send File "docker\transport\npipeconn.py", line 32, in connect File "docker\transport\npipesocket.py", line 23, in wrapped File "docker\transport\npipesocket.py", line 72, in connect File "docker\transport\npipesocket.py", line 52, in connect pywintypes.error: (2, 'CreateFile', 'The system cannot find the file specified.')

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "docker-compose", line 3, in File "compose\cli\main.py", line 81, in main File "compose\cli\main.py", line 200, in perform_command File "compose\cli\command.py", line 60, in project_from_options File "compose\cli\command.py", line 152, in get_project File "compose\cli\docker_client.py", line 41, in get_client File "compose\cli\docker_client.py", line 170, in docker_client File "docker\api\client.py", line 197, in init File "docker\api\client.py", line 221, in _retrieve_server_version docker.errors.DockerException: Error while fetching server API version: (2, 'CreateFile', 'The system cannot find the file specified.') [23380] Failed to execute script docker-compose

spurin commented 3 years ago

I think this might actually be a simple one but the output is super annoying and confusing. Could you please check for me if Docker is running?

jocaputo commented 3 years ago

Thanks for the fast reply. No it's not running.

spurin commented 3 years ago

Hi @jocaputo

Am assuming that this was resolved by starting Docker so for now, I'm just going to close it. If there are any issues outstanding do please let me know.

Best Regards

James Spurin