From 95356986d88371f850cc400559be649cd52d90fd Mon Sep 17 00:00:00 2001 From: Nao Pross Date: Tue, 12 Dec 2023 15:04:37 +0100 Subject: Add Dockerfile without VSCode and Makefile --- Dockerfile | 22 ++++++++++++++++++++++ Makefile | 15 +++++++++++++++ 2 files changed, 37 insertions(+) create mode 100644 Dockerfile create mode 100644 Makefile diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..a9d37e8 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,22 @@ +# See here for image contents: https://github.com/microsoft/vscode-dev-containers/tree/v0.209.6/containers/python-3/.devcontainer/base.Dockerfile + +FROM python:3.10 +WORKDIR /ACT4E + +RUN pip3 --disable-pip-version-check --no-cache-dir install -U pip pre-commit + +# COPY .devcontainer/requirements.txt . +# RUN python3 -m pip install -r requirements.txt + +COPY act4e-mcdp-hotfix ./act4e-mcdp +# RUN python3 -m pip install ./act4e-mcdp +RUN python3 -m pip install git+https://github.com/NaoPross/ACT4E-mcdp.git@make-it-run + +COPY .devcontainer/act4e-check /usr/local/bin +RUN chmod +x /usr/local/bin/act4e-check + +COPY src src +COPY pyproject.toml . + +RUN python3 -m pip install -e . + diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..db1c1a7 --- /dev/null +++ b/Makefile @@ -0,0 +1,15 @@ +tag=act4e-image-mcdp + +.PHONY: build shell check hotfix-test + +build: Dockerfile act4e-mcdp-hotfix + docker build -f Dockerfile -t $(tag) . + +shell: build + docker run -it --rm $(tag) /bin/bash + +check: build + docker run -it --rm $(tag) /bin/bash -c "act4e-mcdp-download-tests --out downloaded && act4e-mcdp-solve-dp-queries --solver act4e_mcdp_solution.DPSolver ./downloaded/lib1-parts" + +hotfix-test: build + docker run -it --rm $(tag) act4e-mcdp-download-tests -- cgit v1.2.1