From 16068da52410a6b36f8aef7b06a0a22587c34804 Mon Sep 17 00:00:00 2001 From: Luca Heltai Date: Tue, 25 Aug 2020 20:46:58 +0200 Subject: [PATCH] Added docker file for master. --- .github/workflows/docker.yml | 20 ++++++++++++++++++++ contrib/docker/Dockerfile | 20 ++++++++++++++++++++ 2 files changed, 40 insertions(+) create mode 100644 .github/workflows/docker.yml create mode 100644 contrib/docker/Dockerfile diff --git a/.github/workflows/docker.yml b/.github/workflows/docker.yml new file mode 100644 index 0000000000..d30205c402 --- /dev/null +++ b/.github/workflows/docker.yml @@ -0,0 +1,20 @@ +name: github-docker + +on: + push: + branches: [master] + +jobs: + build-master-docker: + runs-on: ubuntu-latest + steps: + - name: Build and push Docker image of master + uses: docker/build-push-action@v1 + with: + username: ${{ secrets.DOCKER_USERNAME }} + password: ${{ secrets.DOCKER_PASSWORD }} + cache_froms: dealii/dependencies:focal + repository: dealii/dealii + add_git_labels: true + tags: master-focal + path: contrib/docker diff --git a/contrib/docker/Dockerfile b/contrib/docker/Dockerfile new file mode 100644 index 0000000000..f0244564bf --- /dev/null +++ b/contrib/docker/Dockerfile @@ -0,0 +1,20 @@ +FROM dealii/dependencies:focal + +LABEL maintainer="luca.heltai@gmail.com" + +USER root +RUN git clone https://github.com/dealii/dealii \ + && cd dealii && mkdir build && cd build \ + && cmake -GNinja \ + -DCMAKE_PREFIX_PATH="/usr/lib/x86_64-linux-gnu/hdf5/openmpi;/usr/include/hdf5/openmpi" \ + -DDEAL_II_WITH_MPI=ON \ + -DDEAL_II_WITH_SIMPLEX_SUPPORT=ON \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DDEAL_II_COMPILE_EXAMPLES=OFF \ + .. \ + && ninja install \ + && cd ../../ && rm -rf dealii + +USER $USER +WORKDIR $HOME + -- 2.39.5