Commit 38a331dd authored by Santiago Ospina De Los Ríos's avatar Santiago Ospina De Los Ríos Committed by Lukas Riedel

Merge branch '197-simplify-cloning-dune-modules-and-executing-dunecontrol-script' into 'master'

Resolve "Simplify cloning DUNE modules and executing dunecontrol script"

Closes #197

See merge request !205

(cherry picked from commit 834e62b4)
parent 77874f2e
......@@ -115,8 +115,6 @@ prep:update-dune-clang:
script:
- docker build -f docker/dune-env-update.dockerfile
--build-arg DUNE_ENV_IMAGE=${DUNE_ENV_IMAGE}-clang
--build-arg CC=clang
--build-arg CXX=clang++
--build-arg PROCNUM=$CPUS_DIND
-t ${DUNE_ENV_IMAGE}-clang .
- docker push ${DUNE_ENV_IMAGE}-clang
......
# DORiE Changelog
## Unreleased
### Changed
* Linerar solver for finite volumes changed from `AMG_4_DG` to
`BCGS_AMG_SSOR` !204
* Simplify installation instructions !205
## 2.0.0 (2020-05-14)
### Added
......
This diff is collapsed.
# NOTE: If you want to update this file with options for your own setup, create
# a copy of it. Make sure you *do not* commit any changes specific to your
# setup to the original file!
# CMake configuration options
# - Default build type: Release
# - Create virtual environment in dune-common
# - Fetch pip and install it into virtual environment
# - Prefer parallel over sequential HDF5 (required for Ubuntu/Debian)
CMAKE_FLAGS="
-DCMAKE_BUILD_TYPE=Release
-DDUNE_PYTHON_VIRTUALENV_SETUP=True
-DDUNE_PYTHON_ALLOW_GET_PIP=True
-DHDF5_PREFER_PARALLEL=True
"
#!/usr/bin/env bash
# Abort script on command failure
set -e
echo "=== Cloning DUNE modules into $(pwd) ==="
DEFAULT_BRANCH="releases/2.6"
git clone https://gitlab.dune-project.org/staging/dune-uggrid.git -b $DEFAULT_BRANCH
git clone https://gitlab.dune-project.org/oklein/dune-randomfield.git -b $DEFAULT_BRANCH
git clone https://gitlab.dune-project.org/core/dune-common.git -b $DEFAULT_BRANCH
git clone https://gitlab.dune-project.org/core/dune-geometry.git -b $DEFAULT_BRANCH
git clone https://gitlab.dune-project.org/core/dune-grid.git -b $DEFAULT_BRANCH
git clone https://gitlab.dune-project.org/core/dune-istl.git -b $DEFAULT_BRANCH
git clone https://gitlab.dune-project.org/core/dune-localfunctions.git -b $DEFAULT_BRANCH
git clone https://gitlab.dune-project.org/staging/dune-functions.git -b $DEFAULT_BRANCH
git clone https://gitlab.dune-project.org/pdelab/dune-pdelab.git -b $DEFAULT_BRANCH
git clone https://gitlab.dune-project.org/staging/dune-typetree.git -b $DEFAULT_BRANCH
git clone https://gitlab.dune-project.org/quality/dune-testtools.git -b $DEFAULT_BRANCH
......@@ -9,9 +9,6 @@ LABEL maintainer="lriedel@iup.uni-heidelberg.de"
# number of cores for parallel builds
ARG PROCNUM=1
# Compilers to be used
ARG CC=gcc
ARG CXX=g++
# copy the build context to this image
WORKDIR /opt/dune/dorie
......@@ -20,8 +17,7 @@ COPY ./ ./
# build the executable
WORKDIR /opt/dune/
RUN MAKE_FLAGS="-j${PROCNUM}" \
CMAKE_FLAGS="-DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=${CC} -DCMAKE_CXX_COMPILER=${CXX} -DDUNE_PYTHON_VIRTUALENV_SETUP=True -DDUNE_PYTHON_ALLOW_GET_PIP=True" \
./dune-common/bin/dunecontrol --only=dorie all
./dune-common/bin/dunecontrol --opts=dorie/build.opts --only=dorie all
# Start a fresh image as production environment
FROM $DUNE_ENV_IMAGE as prod-env
......
......@@ -6,13 +6,13 @@ LABEL maintainer="lriedel@iup.uni-heidelberg.de"
# number of cores for parallel builds
ARG PROCNUM=1
# Compilers to be used
ARG CC=gcc
ARG CXX=g++
# Upgrade Ubuntu packages
RUN apt-get clean && apt-get update && apt-get upgrade -y && apt-get clean
# Update and build DUNE modules
WORKDIR /opt/dune
COPY build.opts ./
RUN ./dune-common/bin/dunecontrol update
RUN MAKE_FLAGS="-j ${PROCNUM}" \
CMAKE_FLAGS="-DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=${CC} -DCMAKE_CXX_COMPILER=${CXX} -DDUNE_PYTHON_VIRTUALENV_SETUP=True -DDUNE_PYTHON_ALLOW_GET_PIP=True" \
./dune-common/bin/dunecontrol all
./dune-common/bin/dunecontrol --opts=build.opts all
......@@ -6,6 +6,9 @@ ARG PROCNUM=1
ARG CC=gcc
ARG CXX=g++
# Pass compilers as environment variables (will persist in other images)
ENV CC=$CC CXX=$CXX
# disable any prompts while installing packages
ENV DEBIAN_FRONTEND=noninteractive
RUN apt-get clean \
......@@ -44,19 +47,12 @@ RUN rm -rf /var/lib/apt/lists/* \
ENV LANG en_US.utf8
WORKDIR /opt/dune
RUN git clone https://gitlab.dune-project.org/staging/dune-uggrid.git -b releases/2.6 \
&& git clone https://gitlab.dune-project.org/oklein/dune-randomfield.git -b releases/2.6 \
&& git clone https://gitlab.dune-project.org/core/dune-common.git -b releases/2.6 \
&& git clone https://gitlab.dune-project.org/core/dune-geometry.git -b releases/2.6 \
&& git clone https://gitlab.dune-project.org/core/dune-grid.git -b releases/2.6 \
&& git clone https://gitlab.dune-project.org/core/dune-istl.git -b releases/2.6 \
&& git clone https://gitlab.dune-project.org/core/dune-localfunctions.git -b releases/2.6 \
&& git clone https://gitlab.dune-project.org/staging/dune-functions.git -b releases/2.6 \
&& git clone https://gitlab.dune-project.org/pdelab/dune-pdelab.git -b releases/2.6 \
&& git clone https://gitlab.dune-project.org/staging/dune-typetree.git -b releases/2.6 \
&& git clone https://gitlab.dune-project.org/quality/dune-testtools.git -b releases/2.6
WORKDIR /opt/dune
# Clone DUNE modules
COPY clone_dune ./
RUN bash clone_dune
# Configure and build DUNE modules
COPY build.opts ./
RUN MAKE_FLAGS="-j ${PROCNUM}" \
CMAKE_FLAGS="-DCMAKE_BUILD_TYPE=Release -DCMAKE_C_COMPILER=${CC} -DCMAKE_CXX_COMPILER=${CXX} -DDUNE_PYTHON_VIRTUALENV_SETUP=True -DDUNE_PYTHON_ALLOW_GET_PIP=True" \
./dune-common/bin/dunecontrol all
./dune-common/bin/dunecontrol --opts=build.opts all
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment