gcgarner/IOTstack

Error by starting docker in a Virtual Machine

dolphikcode opened this issue · 7 comments

I have installed IOTstack on Virtual Machine to check how it works (used instruction from github) and when trying to start docker I get:
ERROR: Couldn't connect to Docker daemon at http+docker://localhost - is it running?
If it's at a non-standard location, specify the URL with the DOCKER_HOST environment variable.

I have restarted and recreated yaml but without any better result... Is IOTstack possible to run only on RPi?

The project should run on most Debain based systems. All the images support multi architecture .

I did a quick online search for people having similar issues, there appears to be certain cases that you can't run docker inside a VM. Such as having docker on your local machine and then running a VM with docker. The other option is to check that your virtualisation settings are enabled in your BIOS.

If you have success please let me know about your solution and i will pin the issue

No docker on host and without virtualisation in BIOS it would not be possible to run VM :)

I have found something like this working (running from ~/IOTstack):
export DOCKER_HOST=127.0.0.1:2375
sudo service docker start
sudo docker-compose up -d

No docker on host and without virtualisation in BIOS it would not be possible to run VM :)

fair point

Just to confirm did that solve your issue. And if so does it persist over a reboot? I would like to Pin the solution for others if it does.

Also which distro where you using?

I'm using xUbuntu to have VM lightweight, but normal Ubuntu should also work.

After restarting just need to be started by:
sudo service docker start
sudo docker-compose up -d

Thanks to @dolphikcode for this solution:

if you get the following error:

ERROR: Couldn't connect to Docker daemon at http+docker://localhost - is it running?
Run:

No docker on host and without virtualisation in BIOS it would not be possible to run VM :)

run:

export DOCKER_HOST=127.0.0.1:2375
sudo service docker start
sudo docker-compose up -d

after rebooting you will still need to run

sudo service docker start
sudo docker-compose up -d

I gave it a Quick go as this will make testing a lot easier I get the following error:

pi@IOT-Test:~/IOTstack$ sudo docker-compose up -d Pulling portainer (portainer/portainer:)... latest: Pulling from portainer/portainer ERROR: no matching manifest for unknown in the manifest list entries
Apologies : Using VM VirtualBox with Debian 10 (32 bit)

I had a look at portainer's manifest info and it looks like it is only build for amd64 ARM and PPC

@Paulf007 a 32bit OS is the issue, there is no x86_64 portainer image for you to pull. I've added this issue to the README