Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fails to install Poetry when running docker-compose #18

Open
VigneshPT opened this issue Oct 23, 2018 · 5 comments
Open

Fails to install Poetry when running docker-compose #18

VigneshPT opened this issue Oct 23, 2018 · 5 comments

Comments

@VigneshPT
Copy link

Step 6/8 : RUN poetry install &&     bundler install
 ---> Running in da6a35f96e3d
/bin/sh: poetry: not found
ERROR: Service 'web' failed to build: The command '/bin/sh -c poetry install &&     bundler install' returned a non-zero code: 127

This is the error I get when I run docker-compose up -d

@cosmologist10
Copy link

cosmologist10 commented Mar 5, 2019

I solved this bug, and website is running successfully in my browser, but the main features like pin, follow is incomplete.

@ghost
Copy link

ghost commented Apr 28, 2019

the same problem too

@arakhshan
Copy link

I solved this bug, and website is running successfully in my browser, but the main features like pin, follow is incomplete.

Can you please share your solution. I just faced the same issue.

@mohsen74
Copy link

mohsen74 commented Aug 15, 2019

I solved the problem with changing DockerFile to:

FROM python:2.7

ENV LIBRARY_PATH=/lib:/usr/lib

WORKDIR /stream

ADD . /stream

RUN apt update
RUN apt install -y python-pip
RUN pip install poetry==0.8.1
RUN  poetry install

EXPOSE 8000
CMD ["poetry", "run", "python", "manage.py", "runserver", "0.0.0.0:8000"]

@chusteven
Copy link

In case it helps anyone years later 😅 I kept the same base image but amended just a couple of lines below. Looks like py2-anyjson support was dropped from alpine here and then the poetry stuff I guess was ripped off from above :D

RUN apk add --no-cache --repository http://dl-3.alpinelinux.org/alpine/edge/testing/ \
-    git zlib-dev jpeg-dev gcc musl-dev postgresql-dev py2-anyjson ruby-bundler py2-pip libjpeg curl && \
+    git py-pip zlib-dev jpeg-dev gcc musl-dev postgresql-dev py-anyjson ruby-bundler py2-pip libjpeg curl && \
     curl -sSL https://raw.githubusercontent.com/sdispater/poetry/master/get-poetry.py | python

 WORKDIR /stream

 ADD . /stream

+RUN pip install poetry==0.8.1
 RUN poetry install && \
     bundler install

 EXPOSE 8000

-CMD ["poetry", "run", "python", "manage.py", "runserver", "0.0.0.0:8000"]
+CMD ["poetry", "run", "python", "manage.py", "runserver", "0.0.0.0:8000"]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants