diff --git a/docker/Dockerfile b/docker/Dockerfile index c1929340..f5755bf9 100644 --- a/docker/Dockerfile +++ b/docker/Dockerfile @@ -52,7 +52,10 @@ RUN apt-get -y \ openssh-client && \ apt-get -y clean && \ apt-get -q -y autoremove -RUN pip install --upgrade futures tornado cssmin slimit psutil + +RUN pip install --upgrade pip +COPY requirements.txt /tmp/requirements.txt +RUN pip install -r /tmp/requirements.txt # Create the necessary directories, clone the repo, and install everything RUN mkdir -p /gateone/logs && \ @@ -78,4 +81,4 @@ RUN rm -f /etc/gateone/ssl/key.pem && \ EXPOSE 8000 -CMD ["/usr/local/bin/update_and_run_gateone", "--log_file_prefix=/gateone/logs/gateone.log"] +ENTRYPOINT ["/usr/local/bin/update_and_run_gateone", "--log_file_prefix=/gateone/logs/gateone.log"] diff --git a/docker/Makefile b/docker/Makefile new file mode 100644 index 00000000..830887b8 --- /dev/null +++ b/docker/Makefile @@ -0,0 +1,2 @@ +build: + docker build -t gateone . diff --git a/docker/requirements.txt b/docker/requirements.txt new file mode 100644 index 00000000..bbe167c4 --- /dev/null +++ b/docker/requirements.txt @@ -0,0 +1,5 @@ +cssmin==0.2.* +futures==3.2.* +psutil==5.4.* +slimit==0.8.* +tornado==4.5.* diff --git a/docker/update_and_run_gateone.py b/docker/update_and_run_gateone.py index 31f77d99..2768ec74 100755 --- a/docker/update_and_run_gateone.py +++ b/docker/update_and_run_gateone.py @@ -38,7 +38,6 @@ print("Encountered a problem trying to install/upgrade Gate One...") print(output) sys.exit(1) - retcode, output = getstatusoutput('pip install --upgrade tornado') else: go_args.remove('--noupdate') os.execvp('/usr/bin/python', [