Closed rpitonak closed 6 years ago
https://hub.docker.com/r/usercont/conu/builds/
I tried it locally:
$ make container-image
and this was the output:
docker build --network host --tag=docker.io/usercont/conu:dev . Sending build context to Docker daemon 2.984MB Step 1/7 : FROM registry.fedoraproject.org/fedora:28 ---> e555121ced0f Step 2/7 : ENV PYTHONDONTWRITEBYTECODE=yes ---> Using cache ---> f23f9e5e0f57 Step 3/7 : WORKDIR /src ---> Using cache ---> cb8e1000de8c Step 4/7 : COPY ./requirements.sh /src/ ---> Using cache ---> 758cb8159085 Step 5/7 : RUN ./requirements.sh && dnf clean all ---> Using cache ---> 3d7fe4fde426 Step 6/7 : COPY . /src ---> 670c43db38f1 Step 7/7 : RUN pip3 install --user . && pip2 install --user . ---> Running in fea35c5910e1 WARNING: Running pip install with root privileges is generally not a good idea. Try `pip3 install --user` instead. Processing /src Collecting atomicwrites==1.1.5 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/0a/e8/cd6375e7a59664eeea9e1c77a766eeac0fc3083bb958c2b41ec46b95f29c/atomicwrites-1.1.5-py2.py3-none-any.whl Collecting attrs==18.1.0 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/41/59/cedf87e91ed541be7957c501a92102f9cc6363c623a7666d69d51c78ac5b/attrs-18.1.0-py2.py3-none-any.whl Collecting cachetools==2.1.0 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/0a/58/cbee863250b31d80f47401d04f34038db6766f95dea1cc909ea099c7e571/cachetools-2.1.0-py2.py3-none-any.whl Collecting certifi==2018.4.16 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/7c/e6/92ad559b7192d846975fc916b65f667c7b8c3a32bea7372340bfe9a15fa5/certifi-2018.4.16-py2.py3-none-any.whl (150kB) Collecting chardet==3.0.4 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/bc/a9/01ffebfb562e4274b6487b4bb1ddec7ca55ec7510b22e4c51f14098443b8/chardet-3.0.4-py2.py3-none-any.whl (133kB) Collecting docker-pycreds==0.3.0 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/ea/bf/7e70aeebc40407fbdb96fa9f79fc8e4722ea889a99378303e3bcc73f4ab5/docker_pycreds-0.3.0-py2.py3-none-any.whl Collecting docker==3.4.1 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/a5/64/8c0a5d22e70257e6b7ef7f14b577f99f0b9b1560c604f87856d0db80d151/docker-3.4.1-py2.py3-none-any.whl (124kB) Collecting enum34==1.1.6 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/af/42/cb9355df32c69b553e72a2e28daee25d1611d2c0d9c272aa1d34204205b2/enum34-1.1.6-py3-none-any.whl Collecting google-auth==1.5.1 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/58/cb/96dbb4e50e7a9d856e89cc9c8e36ab1055f9774f7d85f37e2156c1d79d9f/google_auth-1.5.1-py2.py3-none-any.whl (65kB) Collecting idna==2.7 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/4b/2a/0276479a4b3caeb8a8c1af2f8e4355746a97fab05a372e4a2c6a6b876165/idna-2.7-py2.py3-none-any.whl (58kB) Collecting ipaddress==1.0.22 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/fc/d0/7fc3a811e011d4b388be48a0e381db8d990042df54aa4ef4599a31d39853/ipaddress-1.0.22-py2.py3-none-any.whl Collecting kubernetes==6.0.0 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/b4/2a/cd879d216fefd44972705583b077b859ffdb387440c7ca148e48e9e4a212/kubernetes-6.0.0-py2.py3-none-any.whl (1.2MB) Collecting more-itertools==4.3.0 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/79/b1/eace304ef66bd7d3d8b2f78cc374b73ca03bc53664d78151e9df3b3996cc/more_itertools-4.3.0-py3-none-any.whl (48kB) Collecting oauthlib==2.1.0 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/e6/d1/ddd9cfea3e736399b97ded5c2dd62d1322adef4a72d816f1ed1049d6a179/oauthlib-2.1.0-py2.py3-none-any.whl (121kB) Collecting pluggy==0.7.1 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/f5/f1/5a93c118663896d83f7bcbfb7f657ce1d0c0d617e6b4a443a53abcc658ca/pluggy-0.7.1-py2.py3-none-any.whl Requirement already satisfied: py==1.5.4 in /usr/lib/python3.6/site-packages (from conu==0.4.0) Collecting pyasn1-modules==0.2.2 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/19/02/fa63f7ba30a0d7b925ca29d034510fc1ffde53264b71b4155022ddf3ab5d/pyasn1_modules-0.2.2-py2.py3-none-any.whl (62kB) Collecting pyasn1==0.4.4 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/d1/a1/7790cc85db38daa874f6a2e6308131b9953feb1367f2ae2d1123bb93a9f5/pyasn1-0.4.4-py2.py3-none-any.whl (72kB) Collecting pytest==3.7.0 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/9e/a1/8166a56ce9d89fdd9efcae5601e71758029d90e5644e0b7b6eda07e67c35/pytest-3.7.0-py2.py3-none-any.whl (202kB) Collecting python-dateutil==2.7.3 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/cf/f5/af2b09c957ace60dcfac112b669c45c8c97e32f94aa8b56da4c6d1682825/python_dateutil-2.7.3-py2.py3-none-any.whl (211kB) Collecting pyxattr==0.6.1 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/36/1d/1a5f3165f330e1a0427636f2bd995dbcc02d0f7660e89458d64806a2ed1e/pyxattr-0.6.1.tar.gz Collecting pyyaml==3.13 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/9e/a3/1d13970c3f36777c583f136c136f804d70f500168edc1edea6daa7200769/PyYAML-3.13.tar.gz (270kB) Collecting requests-oauthlib==1.0.0 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/94/e7/c250d122992e1561690d9c0f7856dadb79d61fd4bdd0e598087dce607f6c/requests_oauthlib-1.0.0-py2.py3-none-any.whl Collecting requests==2.19.1 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/65/47/7e02164a2a3db50ed6d8a6ab1d6d60b69c4c3fdf57a284257925dfc12bda/requests-2.19.1-py2.py3-none-any.whl (91kB) Collecting rsa==3.4.2 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/e1/ae/baedc9cb175552e95f3395c43055a6a5e125ae4d48a1d7a924baca83e92e/rsa-3.4.2-py2.py3-none-any.whl (46kB) Requirement already satisfied: six==1.11.0 in /usr/lib/python3.6/site-packages (from conu==0.4.0) Collecting urllib3==1.23 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/bd/c9/6fdd990019071a4a32a5e7cb78a1d92c53851ef4f56f62a3486e6a7d8ffb/urllib3-1.23-py2.py3-none-any.whl (133kB) Collecting websocket-client==0.48.0 (from conu==0.4.0) Downloading https://files.pythonhosted.org/packages/8a/a1/72ef9aa26cfe1a75cee09fc1957e4723add9de098c15719416a1ee89386b/websocket_client-0.48.0-py2.py3-none-any.whl (198kB) Requirement already satisfied: setuptools>=21.0.0 in /usr/lib/python3.6/site-packages (from kubernetes==6.0.0->conu==0.4.0) Installing collected packages: atomicwrites, attrs, cachetools, certifi, chardet, docker-pycreds, urllib3, idna, requests, websocket-client, docker, enum34, pyasn1, pyasn1-modules, rsa, google-auth, ipaddress, oauthlib, requests-oauthlib, python-dateutil, pyyaml, kubernetes, more-itertools, pluggy, pytest, pyxattr, conu Running setup.py install for pyyaml: started Running setup.py install for pyyaml: finished with status 'done' Running setup.py install for pyxattr: started Running setup.py install for pyxattr: finished with status 'error' Complete output from command /usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-u__r78e1/pyxattr/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-1bh94sck-record/install-record.txt --single-version-externally-managed --compile --user --prefix=: running install running build running build_ext building 'xattr' extension creating build creating build/temp.linux-x86_64-3.6 gcc -pthread -Wno-unused-result -Wsign-compare -DDYNAMIC_ANNOTATIONS_ENABLED=1 -DNDEBUG -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -Wp,-D_GLIBCXX_ASSERTIONS -fexceptions -fstack-protector-strong -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 -m64 -mtune=generic -fasynchronous-unwind-tables -fstack-clash-protection -mcet -fcf-protection -D_GNU_SOURCE -fPIC -fwrapv -fPIC -D_XATTR_VERSION="0.6.1" -D_XATTR_AUTHOR="Iustin Pop" -D_XATTR_EMAIL="iustin@k1024.org" -I/usr/include/python3.6m -c xattr.c -o build/temp.linux-x86_64-3.6/xattr.o -Wall -Werror -Wsign-compare unable to execute 'gcc': No such file or directory error: command 'gcc' failed with exit status 1 ---------------------------------------- Command "/usr/bin/python3 -u -c "import setuptools, tokenize;__file__='/tmp/pip-build-u__r78e1/pyxattr/setup.py';f=getattr(tokenize, 'open', open)(__file__);code=f.read().replace('\r\n', '\n');f.close();exec(compile(code, __file__, 'exec'))" install --record /tmp/pip-1bh94sck-record/install-record.txt --single-version-externally-managed --compile --user --prefix=" failed with error code 1 in /tmp/pip-build-u__r78e1/pyxattr/ The command '/bin/sh -c pip3 install --user . && pip2 install --user .' returned a non-zero code: 1 make: *** [container-image] Error 1
Workaround is to delete pyxattr==0.6.1 from requirements.txt, because it is already installed from requirements.sh, but I am not sure if it is best solution.
pyxattr==0.6.1
oh right, so we have different version of pyxattr in Fedora than in req.txt
The easiest solution is to install gcc and python-devel in the image so it compiles fine.
https://hub.docker.com/r/usercont/conu/builds/
I tried it locally:
and this was the output:
Workaround is to delete
pyxattr==0.6.1
from requirements.txt, because it is already installed from requirements.sh, but I am not sure if it is best solution.