Tethys Docker Issues

59 views
Skip to first unread message

david...@gmail.com

unread,
Oct 9, 2017, 12:47:03 PM10/9/17
to Tethys Platform
I just installed tethys and when I try to run the tethys docker init command I get this code:

Tethys Apps Loaded:
Traceback (most recent call last):
  File "/home/davidbell74/tethys/miniconda/envs/tethys/bin/tethys", line 11, in <module>
    load_entry_point('tethys-platform', 'console_scripts', 'tethys')()
  File "/home/davidbell74/tethys/src/tethys_apps/cli/__init__.py", line 294, in tethys_command
    args.func(args)
  File "/home/davidbell74/tethys/src/tethys_apps/cli/__init__.py", line 62, in docker_command
    docker_init(containers=args.containers, defaults=args.defaults)
  File "/home/davidbell74/tethys/src/tethys_apps/cli/docker_commands.py", line 951, in docker_init
    docker_client = get_docker_client()
  File "/home/davidbell74/tethys/src/tethys_apps/cli/docker_commands.py", line 246, in get_docker_client
    version = get_api_version(MAX_CLIENT_DOCKER_API_VERSION, version_client.version()['ApiVersion'])
  File "/home/davidbell74/tethys/miniconda/envs/tethys/lib/python2.7/site-packages/docker/api/daemon.py", line 76, in version
    return self._result(self._get(url), json=True)
  File "/home/davidbell74/tethys/miniconda/envs/tethys/lib/python2.7/site-packages/docker/utils/decorators.py", line 47, in inner
    return f(self, *args, **kwargs)
  File "/home/davidbell74/tethys/miniconda/envs/tethys/lib/python2.7/site-packages/docker/client.py", line 120, in _get
    return self.get(url, **self._set_request_timeout(kwargs))
  File "/home/davidbell74/tethys/miniconda/envs/tethys/lib/python2.7/site-packages/requests/sessions.py", line 521, in get
    return self.request('GET', url, **kwargs)
  File "/home/davidbell74/tethys/miniconda/envs/tethys/lib/python2.7/site-packages/requests/sessions.py", line 508, in request
    resp = self.send(prep, **send_kwargs)
  File "/home/davidbell74/tethys/miniconda/envs/tethys/lib/python2.7/site-packages/requests/sessions.py", line 618, in send
    r = adapter.send(request, **kwargs)
  File "/home/davidbell74/tethys/miniconda/envs/tethys/lib/python2.7/site-packages/requests/adapters.py", line 490, in send
    raise ConnectionError(err, request=request)
requests.exceptions.ConnectionError: ('Connection aborted.', error(13, 'Permission denied'))

swainn

unread,
Oct 12, 2017, 5:04:19 PM10/12/17
to Tethys Platform
Can you run this command without "sudo":

$ docker ps

If not, then you need to follow these instructions for adding your user to the Docker group:

sudo groupadd docker

Then logout and log back in to effect the change and try running the docker ps command again (without sudo).

If that works, try the tethys docker init command again.

david...@gmail.com

unread,
Oct 13, 2017, 10:18:27 AM10/13/17
to Tethys Platform
I tried the docker ps command and got this

Got permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.32/containers/json: dial unix /var/run/docker.sock: connect: permission denied

So I did the sudo groupadd docker and got this

groupadd: group 'docker' already exists

I logged off and back in and the docker ps still gives the same code as before.

Scott Christensen

unread,
Oct 13, 2017, 12:07:43 PM10/13/17
to david...@gmail.com, Tethys Platform
try running:

newgrp docker

and then running the tethys command again. What version of Linux are you on?

--
You received this message because you are subscribed to the Google Groups "Tethys Platform" group.
To unsubscribe from this group and stop receiving emails from it, send an email to tethysplatfor...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/tethysplatform/4a7d7881-2e3f-4528-8afc-6ee742581f1a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
Scott D. Christensen, PhD
Research Civil Engineer
Information Technology Laboratory  
US Army Corps of Engineers
 

david...@gmail.com

unread,
Oct 16, 2017, 10:08:12 AM10/16/17
to Tethys Platform
I installed onto Ubuntu 17.04

Ezra Rice

unread,
Oct 16, 2017, 8:19:02 PM10/16/17
to david...@gmail.com, Tethys Platform
I recently had this same issue and I fixed it by adding my user to the docker group. For some reason the installation script didn't add my user.

$ sudo usermod -aG docker $USER

Don't forget to logout then login for changes to take effect.
See the official Docker documentation under step 2 in creating the docker group.



For more options, visit https://groups.google.com/d/optout.
--
Ezra Rice

"Try not to become a man of success, but rather try to become a man of value." - Albert Einstein

david...@gmail.com

unread,
Oct 17, 2017, 10:36:38 AM10/17/17
to Tethys Platform
I still get the same error code after logging out and back on
Reply all
Reply to author
Forward
0 new messages