From 3ac9ecbd8f4cb5a6c99a2167dd1bf2570221ac1b Mon Sep 17 00:00:00 2001 From: Fabio Manganiello Date: Mon, 2 Dec 2019 00:34:32 +0100 Subject: [PATCH] Do git clone and explicit pip install -r requirements.txt in platydock to make sure that all the recommended dependencies are installed --- platypush/platydock/__init__.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/platypush/platydock/__init__.py b/platypush/platydock/__init__.py index 94d806dee..9e8c1f782 100755 --- a/platypush/platydock/__init__.py +++ b/platypush/platydock/__init__.py @@ -92,7 +92,8 @@ def generate_dockerfile(deps, ports, cfgfile, devdir, python_version): content += textwrap.dedent( ''' - RUN pip install git+https://github.com/BlackLight/platypush.git + RUN git clone https://github.com/BlackLight/platypush.git /app && cd /app + RUN pip install -r requirements.txt && python setup.py build install RUN apk del git && apk del build-base ''') @@ -100,7 +101,7 @@ def generate_dockerfile(deps, ports, cfgfile, devdir, python_version): for port in ports: content += 'EXPOSE {}\n'.format(port) - content += '\nCMD ["python3", "-m", "platypush"]\n' + content += '\nCMD ["python", "-m", "platypush"]\n' dockerfile = os.path.join(devdir, 'Dockerfile') print('Generating Dockerfile {}'.format(dockerfile))