-
Notifications
You must be signed in to change notification settings - Fork 394
linux spec user: unable to find user root: no matching entries in passwd file #400
Comments
@dougbtv, I'm confused by your
This is an empty play, meaning there are no tasks. However, I suspect that Ansible may still be attempting to connect to each (or |
@chouseknecht thanks for the eyes to check that out. Wondering where I got that, I think it was copy-pasta from some reference ansible-container main.yml I found in the wild. I went ahead and re-ran it with
And I had the same results:
Something that also jumps out at me is:
In this case, I don't actually need to or want to customize this image. Is there a way to specifically say in the I tried reading through the container.yml reference but, I'm not seeing anything there. Seeing it's a really stripped down image that I don't want to modify, I'm wondering if it's having trouble trying to run it "in a special ansible-containers" way. Thanks again, too! |
I'm running into this issue too.
this is my
the ansible-ssportal role just tries to install |
I encountered the same issue with a similar setup:
Where the testapp role actually uses python:3 as the base image. Thus try pulling ubuntu:16.04 and see if it helps (since your conductor uses 16.10) |
Was running into this issue and think it would be a cool feature when passing around ansible-container projects, to be able to pull necessary docker images before running ansible-container build project. Or if docker images not found locally or remotely, throwing a better warning |
@mhumeSF Actually I'd consider it more of a bug, since if it handles fetching the conductor image from remote, it should also be able to do the same for each service built. |
I have the same problem -- running on macos 10.10.5 with Docker version 17.03.1-ce, build c6d412e and current ansible-container develop branch. It seems to go away if add a dummy service at the beginning that just loads the centos image and does nothing else, e.g.: services:
test:
from: 'centos:7' |
Can you share a more complete Thanks! |
@chouseknecht -- unreal, I'm just trying to reproduce it again (after staring at that error for many hours yesterday) and I cannot. I will report back here if I manage to break it again. I believe what fixed it was
|
Having trouble creating a reproducible test case, but our scenario is referencing an image from a private aws container repo. These containers are referenced from the local tag name. If the containers have not been pulled from the private repo and tagged appropriately, the error above happens. I do see the |
I have reproduced this issue with the following
The
This is what I get from running
I'm using the HEAD of develop:
|
Yes, i have the same problem with the same version: Traceback (most recent call last):
File "/usr/local/bin/conductor", line 11, in <module>
load_entry_point('ansible-container', 'console_scripts', 'conductor')()
File "/_ansible/container/__init__.py", line 19, in __wrapped__
return fn(*args, **kwargs)
File "/_ansible/container/cli.py", line 378, in conductor_commandline
**params)
File "/_ansible/container/__init__.py", line 19, in __wrapped__
return fn(*args, **kwargs)
File "/_ansible/container/core.py", line 736, in conductorcmd_build
container_id = engine.run_container(cur_image_id, service_name, **run_kwargs)
File "/_ansible/container/docker/engine.py", line 83, in __wrapped__
return fn(self, *args, **kwargs)
File "/_ansible/container/__init__.py", line 19, in __wrapped__
return fn(*args, **kwargs)
File "/_ansible/container/docker/engine.py", line 202, in run_container
**run_kwargs
File "/usr/local/lib/python2.7/dist-packages/docker/models/containers.py", line 703, in run
container.start()
File "/usr/local/lib/python2.7/dist-packages/docker/models/containers.py", line 333, in start
return self.client.api.start(self.id, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/docker/utils/decorators.py", line 19, in wrapped
return f(self, resource_id, *args, **kwargs)
File "/usr/local/lib/python2.7/dist-packages/docker/api/container.py", line 1079, in start
self._raise_for_status(res)
File "/usr/local/lib/python2.7/dist-packages/docker/api/client.py", line 222, in _raise_for_status
raise create_api_error_from_http_exception(e)
File "/usr/local/lib/python2.7/dist-packages/docker/errors.py", line 31, in create_api_error_from_http_exception
raise cls(e, response=response, explanation=explanation)
docker.errors.APIError: 500 Server Error: Internal Server Error ("linux spec user: unable to find user root: no matching entries in passwd file")
2017-07-11T02:21:52.089779 Conductor terminated. Cleaning up. [container.docker.engine] caller_file=/home/salahaddin/Proyectos/Works/text-ansible-container/ansible-container/container/docker/engine.py caller_func=await_conductor_command caller_line=356 command_rc=1 conductor_id=089b46a965035175845fac5ba3436af60dbafcc336ff6e835bb33868c48926a2 save_container=False
2017-07-11T02:21:52.703598 Conductor exited with status 1 [container.cli] caller_file=/home/salahaddin/Proyectos/Works/text-ansible-container/ansible-container/container/cli.py caller_func=__call__ caller_line=290 |
I think I have found what is happening with this issues and how to reproduce it.
============================================================================= The logs bellow are from when the image postgres:9.3 was previously downloaded.
|
@asantos82 Yes, you are right, i pulled all image from my container before to build the container and this bug dissapeared. |
@SalahAdDin @asantos82 I'm glad you confirmed that my proposed workaround (#400 (comment)) works :) |
Still having the same problem with current version 0.9.2 and Docker 18.03.0-ce-rc1 on MacOS 10.13. Using the following container.yml: version: "2" settings: project_name: xyz services: Image IS loaded prior to ansible-container build: docker image lsREPOSITORY TAG IMAGE ID CREATED SIZE docker pull traefikUsing default tag: latest ansible-container --debug build2018-03-07T22:30:53.922768 Cleaning up temporary directory [container.utils.temp] caller_file=/usr/local/lib/python2.7/site-packages/container/utils/temp.py caller_func=exit caller_line=22 path=/var/folders/xn/4kfjy25n20qcxpjm2nqjwtl80000gn/T/tmpEILcLR Maybe it has something to do with the entrypoint/cmd that is set by ansible-container? docker ps -aCONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES Here I see that the cmd is set to something with "sh -c 'while..." instead of the specified command in the container.yml file. Best regards, |
ISSUE TYPE
container.yml
main.yml
OS / ENVIRONMENT
SUMMARY
When running a container that is supposed to be run from a downloaded image (e.g. not one managed by this ansible-container project) it happens to fail with this error:
In this case the image specifically is
traefik
and likely uses alpine linux.The
container.yml
is borrowed from a workingdocker-compose.yml
(with docker-compose, as you'd guess).STEPS TO REPRODUCE
EXPECTED RESULTS
No error.
ACTUAL RESULTS
The text was updated successfully, but these errors were encountered: