Skip to content
Snippets Groups Projects
Commit 0559b7a6 authored by Paul McCarthy's avatar Paul McCarthy :mountain_bicyclist:
Browse files

CI: Pre-build docker image for make testing faster

parent 2f3f7a5f
No related branches found
No related tags found
1 merge request!4ENH: Config file templating
stages:
- docker
- test
.test: &test_template
# Build docker image used for unit tests
build-dev-docker-image:
stage: docker
image: docker:latest
tags:
- docker_build
services:
- docker:dind
when: manual
allow_failure: true
script:
- mkdir -p $HOME/.docker/
- echo $DOCKER_AUTH_CONFIG > $HOME/.docker/config.json
- TAG="$(date +%Y%m%d).${CI_COMMIT_SHORT_SHA}"
- IMAGE="pauldmccarthy/bip-dev"
- DOCKERFILE=docker/Dockerfile
- docker build -t "${IMAGE}:${TAG}" -t "${IMAGE}:latest" -f ${DOCKERFILE} ./docker
- docker push "${IMAGE}:${TAG}"
- docker push "${IMAGE}:latest"
test:
stage: test
image: continuumio/miniconda3
image: pauldmccarthy/bip-dev
tags:
- docker
except:
......@@ -12,9 +34,3 @@ stages:
- merge_requests
script:
- ./.ci/unit_tests.sh
test:3.11:
variables:
PYTHON_VERSION : "3.11"
<<: *test_template
FROM continuumio/miniconda3
MAINTAINER Paul McCarthy <pauldmccarthy@gmail.com>
ENV PYTHON_VERSION "3.11"
COPY /create_dev_env.sh /create_dev_env.sh
RUN /bin/bash /create_dev_env.sh /dev.env
......@@ -23,3 +23,5 @@ source activate ${envdir}
pip install dmri-amico
pip install git+https://git.fmrib.ox.ac.uk/ndcn0236/pipe-tree.git
pip install git+https://git.fmrib.ox.ac.uk/fsl/gradunwarp.git
# CREATE DOCKER IMAGE
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment