1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60
|
# This docker-compose file is used to build the RDKit MinimalLib
# from either GitHub or a local source tree.
# The build consists of three stages (services):
# 1. `deps`: This service builds the dependencies required for RDKit.
# 2. `rdkit_get_src`: This service gets the RDKit source code from
# either from GitHub (GET_SRC=clone_from_github, the default)
# or from a local source tree (GET_SRC=copy_from_local)
# into the Docker image.
# 3. `rdkit_build`: This service builds the RDKit MinimalLib using
# the dependencies built in the first service and the source code
# copied in the second service.
#
# Example usage:
# (the --build-arg are all optional)
#
# GET_SRC=copy_from_local \
# docker-compose -f docker_compose_build_minimallib.yml build \
# --build-arg http_proxy=$HTTP_PROXY \
# --build-arg http_proxy=$HTTP_PROXY \
# --build-arg https_proxy=$HTTP_PROXY \
# --build-arg "EXCEPTION_HANDLING=-fwasm-exceptions" \
# 2>&1 | tee docker-compose.log
#
# Once the build is finished, you can run the following command to
# export the buildartifacts to your local filesystem:
#
# DOCKER_BUILDKIT=1 docker build -f Dockerfile_4_rdkit_export -o ../demo .
services:
rdkit_deps:
environment:
- NETWORK_MODE=${NETWORK_MODE:-bridge}
network_mode: ${NETWORK_MODE:-bridge}
build:
context: .
dockerfile: Dockerfile_1_deps
image: rdkit-minimallib-deps:latest
rdkit_get_src:
environment:
- NETWORK_MODE=${NETWORK_MODE:-bridge}
- GET_SRC=${GET_SRC:-clone_from_github}
network_mode: ${NETWORK_MODE:-bridge}
build:
context: ../../..
dockerfile: ./Code/MinimalLib/docker/Dockerfile_2_rdkit_${GET_SRC:-clone_from_github}
image: rdkit-minimallib-rdkit-src:latest
depends_on:
- rdkit_deps
rdkit_build:
environment:
- NETWORK_MODE=${NETWORK_MODE:-bridge}
network_mode: ${NETWORK_MODE:-bridge}
build:
context: .
dockerfile: Dockerfile_3_rdkit_build
image: rdkit-minimallib:latest
depends_on:
- rdkit_get_src
|