From cdbb4f46888ad8841e8d6e70d3f2f89a1e717487 Mon Sep 17 00:00:00 2001 From: Clemens Klug Date: Tue, 29 May 2018 11:33:17 +0200 Subject: [PATCH] dockerize --- Dockerfile | 4 ++++ Readme.md | 31 +++++++++++++++++++++++++++++++ Readme.rst | 14 -------------- docker-compose.yml | 6 ++++++ 4 files changed, 41 insertions(+), 14 deletions(-) create mode 100644 Dockerfile create mode 100644 Readme.md delete mode 100644 Readme.rst create mode 100644 docker-compose.yml diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..23231b8 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,4 @@ +FROM alpine:3.7 +ADD . / +RUN apk add --update --no-cache python3 && pip3 --no-cache-dir install -r requirements.txt +ENTRYPOINT ["python3", "dudle2csv.py"] \ No newline at end of file diff --git a/Readme.md b/Readme.md new file mode 100644 index 0000000..12c3b84 --- /dev/null +++ b/Readme.md @@ -0,0 +1,31 @@ +# Usage + +Steps in [] are optional + +## Docker (compose) + +### Docker-compose + +* [`docker-compose build`] +* `docker-compose run dudle2csv ` [> data.csv] +* [`docker-compose down --remove-orphans`] +* [`docker rmi fswiai/dudle2csv:0.1`] + +### Docker + +* `docker built -t fswiai/dudle2csv:0.1 .` +* `docker run --rm fswiai/dudle2csv:0.1 ` [> data.csv] +* [`docker rmi fswiai/dudle2csv:0.1`] + + +## lame + +### Preparation + +* [make virtualenv: `python3 -m venv .venv`] +* [activate venv: `source .venv/bin/activate`] +* install dependencies: `pip3 install -r requirements.txt` + +### Run + +`python3 dudle2csv.py -h` diff --git a/Readme.rst b/Readme.rst deleted file mode 100644 index ac11208..0000000 --- a/Readme.rst +++ /dev/null @@ -1,14 +0,0 @@ -Usage -===== - -Preparation ------------ - -* [make virtualenv: `python3 -m venv .venv`] -* [activate venv: `source .venv/bin/activate`] -* install dependencies: `pip3 install -r requirements.txt` - -Run ---- - -`python3 dudle2csv.py -h` diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..fb922b1 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,6 @@ +version: "3" + +services: + dudle2csv: + build: . + image: fswiai/dudle2csv:0.1 \ No newline at end of file