Skip to main content

OGS Container Maker

Project description

OGS Container Maker

General usage

Installation

virtualenv ~/.venv/ogs-container-maker
source ~/.venv/ogs-container-maker/bin/activate
pip install ogscm

Generate container definition

$ ogscm
Creating 1 image definition(s)...
Created definition _out/docker/ubuntu_17.10/ogs-4c7de6a4/serial/conan/cmake-d41d8cd9/Dockerfile 

# With user options
$ ogscm --format singularity --ompi 2.1.3 --cmake_args ' -DOGS_BUILD_PROCESSES=GroundwaterFlow'
Creating 1 image definition(s)...
Created definition _out/singularity/ubuntu_17.10/ogs-4c7de6a4/openmpi-2.1.3/conan/cmake-fde09bf7/Singularity.de

Build image

Add the --build-flag.

Convert Docker image to Singularity image:

Add the --convert-flag (requires Singularity 3.x).

Run

docker run --it --rm ogs-ompi-2.1.3
# in container:
ogs --version
singularity shell ogs-ompi-2.1.3.sif
# in container:
ogs --version
# OR directly run from host
singularity exec ogs-ompi-2.1.3.sif ogs local/path/to/square_1e0.prj

Using the combinatorial builder

Creates Docker definition files with different OpenMPI implementations and OpenGeoSys parallel configuration (from the current master), builds the docker images and converts them to Singularity images:

python build.py --ogs ufz/ogs@master --ompi 2.1.2 3.1.2 --build --convert

Check help for more options:

$ ogscm --help
usage: ogscm [-h] [--recipe RECIPE] [--out OUT] [--file FILE] [--print]
             [--format [{docker,singularity} [{docker,singularity} ...]]]
             [--pm [{system,conan} [{system,conan} ...]]]
             [--ompi [OMPI [OMPI ...]]] [--ogs [OGS [OGS ...]]]
             [--cmake_args [CMAKE_ARGS [CMAKE_ARGS ...]]] [--build] [--upload]
             [--registry REGISTRY] [--convert] [--runtime-only]
             [--base_image BASE_IMAGE] [--clang] [--gui] [--docs] [--jenkins]
             [--cvode] [--cppcheck] [--iwyy] [--gcovr] [--dev]
             [--compiler_version COMPILER_VERSION]

Generate container image definitions.

optional arguments:
  -h, --help            show this help message and exit
  --recipe RECIPE       HPCCM recipe (default: recipes/ogs-builder.py)
  --out OUT             Output directory (default: _out)
  --file FILE           Overwrite output recipe file name (default: )
  --print, -P           Print the definition to stdout (default: False)

Combinatorial options:
  All combinations of the given options will be generated

  --format [{docker,singularity} [{docker,singularity} ...]]
  --pm [{system,conan} [{system,conan} ...]]
                        Package manager to install third-party dependencies
                        (default: ['conan'])
  --ompi [OMPI [OMPI ...]]
                        OpenMPI version, e.g. 2.1.1, 2.1.5, 3.0.1, 3.1.2
                        (default: ['off'])
  --ogs [OGS [OGS ...]]
                        OGS GitHub repo in the form 'user/repo@branch' or
                        'off' to disable OGS building (default:
                        ['ufz/ogs@master'])
  --cmake_args [CMAKE_ARGS [CMAKE_ARGS ...]]
                        CMake argument sets have to be quoted and **must**
                        start with a space. e.g. --cmake_args ' -DFIRST=TRUE
                        -DFOO=BAR' ' -DSECOND=TRUE' (default: [''])

Image build options:
  --build, -B           Build the images from the definition files (default:
                        False)
  --upload, -U          Upload Docker image to registry (default: False)
  --registry REGISTRY   The docker registry the image is tagged and uploaded
                        to. (default: registry.opengeosys.org/ogs/ogs)
  --convert, -C         Convert Docker image to Singularity image (default:
                        False)
  --runtime-only, -R    Generate multi-stage Dockerfiles for small runtime
                        images (default: False)

Additional options:
  --base_image BASE_IMAGE
                        The base image. 'centos:7' is supported too. (default:
                        ubuntu:17.10)
  --clang               Use clang instead of gcc (default: False)
  --gui                 Builds the GUI (Data Explorer) (default: False)
  --docs                Setup documentation requirements (Doxygen) (default:
                        False)
  --jenkins             Setup Jenkins slave (default: False)
  --cvode               Install and configure with cvode (default: False)
  --cppcheck            Install cppcheck (default: False)
  --iwyy                Install include-what-you-use (default: False)
  --gcovr               Install gcovr (default: False)
  --dev                 Installs development tools (vim, gdb) (default: False)
  --compiler_version COMPILER_VERSION
                        Compiler version. (default: )

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ogscm-1.2.0.tar.gz (17.5 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

ogscm-1.2.0-py3.7.egg (74.5 kB view details)

Uploaded Egg

ogscm-1.2.0-py3-none-any.whl (31.5 kB view details)

Uploaded Python 3

File details

Details for the file ogscm-1.2.0.tar.gz.

File metadata

  • Download URL: ogscm-1.2.0.tar.gz
  • Upload date:
  • Size: 17.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.2

File hashes

Hashes for ogscm-1.2.0.tar.gz
Algorithm Hash digest
SHA256 7fb60ea5c22c6783365bd6c51931630d667e6b11010f41d088c7aa5f4df01640
MD5 cc47bd92a90e0425c6b311e1de931a1d
BLAKE2b-256 de0b276a1a82fab391a64ab976ddc4f9ab6e2504e6bcd2bfd4e58fa85ea55964

See more details on using hashes here.

File details

Details for the file ogscm-1.2.0-py3.7.egg.

File metadata

  • Download URL: ogscm-1.2.0-py3.7.egg
  • Upload date:
  • Size: 74.5 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.6

File hashes

Hashes for ogscm-1.2.0-py3.7.egg
Algorithm Hash digest
SHA256 e682ddfde65af065e7c65d5f23a3012bf9c44d5d21ecaae7bb33b9136ef7e63b
MD5 93fd61c6e4e63d158f290ed8fb3d2dcd
BLAKE2b-256 06b57c9cc3683600b77fb4daf5c2466db1830a831e3366ea306f76d9c84dbc0e

See more details on using hashes here.

File details

Details for the file ogscm-1.2.0-py3-none-any.whl.

File metadata

  • Download URL: ogscm-1.2.0-py3-none-any.whl
  • Upload date:
  • Size: 31.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.7.2

File hashes

Hashes for ogscm-1.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d003ecb087633beb12a5bc7685a0b5c897c12fff45fe65f954093b961e82312f
MD5 4101307b5ae5861873bbc6d0a9e9a860
BLAKE2b-256 50068f1dce7f64cd578262dbb700e460aee8098d2b90338d520ad6576d687254

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page