From a774e3ff8d763116f96c88012e5b0671e3cc2130 Mon Sep 17 00:00:00 2001 From: Casper da Costa-Luis Date: Mon, 25 Jan 2021 14:51:28 +0000 Subject: [PATCH] remove Dockerfile - fixes #1119 --- .github/workflows/test.yml | 2 +- .gitignore | 1 + Dockerfile | 4 ---- Makefile | 4 ++++ 4 files changed, 6 insertions(+), 5 deletions(-) delete mode 100644 Dockerfile diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 1f13be4e..6788a783 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -132,7 +132,7 @@ jobs: run: | sudo apt-get install -yqq pandoc pip install .[dev] - make build .dockerignore snapcraft.yaml + make build .dockerignore Dockerfile snapcraft.yaml - id: dist uses: casperdcl/deploy-pypi@v2 with: diff --git a/.gitignore b/.gitignore index 26e23084..165e08ef 100644 --- a/.gitignore +++ b/.gitignore @@ -12,6 +12,7 @@ __pycache__/ /snapcraft.yaml /tqdm_*.snap /.dockerignore +/Dockerfile # Unit test / coverage reports /.tox/ diff --git a/Dockerfile b/Dockerfile deleted file mode 100644 index 96f9dc4e..00000000 --- a/Dockerfile +++ /dev/null @@ -1,4 +0,0 @@ -FROM python:3.7-alpine -COPY dist/*.whl . -RUN pip install -U $(ls ./*.whl) && rm ./*.whl -ENTRYPOINT ["tqdm"] diff --git a/Makefile b/Makefile index 879d7546..10da5a9e 100644 --- a/Makefile +++ b/Makefile @@ -107,6 +107,9 @@ snapcraft.yaml: .meta/mksnap.py .dockerignore: @+python -c "fd=open('.dockerignore', 'w'); fd.write('*\n!dist/*.whl\n')" +Dockerfile: + @+python -c 'fd=open("Dockerfile", "w"); fd.write("FROM python:3.8-alpine\nCOPY dist/*.whl .\nRUN pip install -U $$(ls ./*.whl) && rm ./*.whl\nENTRYPOINT [\"tqdm\"]\n")' + distclean: @+make coverclean @+make prebuildclean @@ -167,6 +170,7 @@ snap: docker: @make build @make .dockerignore + @make Dockerfile docker build . -t tqdm/tqdm docker tag tqdm/tqdm:latest tqdm/tqdm:$(shell docker run -i --rm tqdm/tqdm -v) none: