From 6038351b7172fa572395d4fceaf1c1d60cefe225 Mon Sep 17 00:00:00 2001 From: Mark Meredith Date: Sun, 18 Oct 2020 18:21:08 -0400 Subject: [PATCH 1/3] Update versions of dependencies --- .gitlab-ci.yml | 2 +- conanfile.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 2cf3749..a1cca7d 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,4 +1,4 @@ -image: python:3.7.7-buster +image: python:3.8.6-buster variables: GIT_STRATEGY: fetch diff --git a/conanfile.py b/conanfile.py index d0924b1..eb21706 100644 --- a/conanfile.py +++ b/conanfile.py @@ -15,9 +15,9 @@ class CsgEbConan(ConanFile): options = {"shared": [True, False]} default_options = {"shared": False} generators = "pkg_config" - requires = ("catch2/2.13.0", "cgal/5.0.2", "taocpp-pegtl/2.8.3") + requires = ("catch2/2.13.2", "cgal/5.1", "taocpp-pegtl/2.8.3") build_requires = ( - "meson/0.55.0", + "meson/0.55.3", "pkg-config_installer/0.29.2@bincrafters/stable", ) exports_sources = "meson.build", "include/*", "src/*" -- GitLab From 8a9cc54a33e139508c7066a1cb921dfe6cb93895 Mon Sep 17 00:00:00 2001 From: Mark Meredith Date: Sun, 18 Oct 2020 18:30:18 -0400 Subject: [PATCH 2/3] simplify --- .gitlab-ci.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index a1cca7d..ae9feab 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,8 +1,4 @@ -image: python:3.8.6-buster - -variables: - GIT_STRATEGY: fetch - GIT_SUBMODULE_STRATEGY: normal +image: python:3.8.6 ###### Test jobs ##### -- GitLab From f363b5aee6d28ec141eba7de85337ba53d00464c Mon Sep 17 00:00:00 2001 From: Mark Meredith Date: Sun, 18 Oct 2020 22:33:00 -0400 Subject: [PATCH 3/3] build container image with kaniko --- .gitlab-ci.yml | 29 +++++++++++++++++++++++++---- Dockerfile | 11 +++++++++++ 2 files changed, 36 insertions(+), 4 deletions(-) create mode 100644 Dockerfile diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index ae9feab..9f99070 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -1,13 +1,32 @@ image: python:3.8.6 +stages: + - build-img + - test + +build-img: + stage: build-img + image: + name: gcr.io/kaniko-project/executor:debug + entrypoint: [""] + script: + - mkdir -p /kaniko/.docker + - echo "{\"auths\":{\"$CI_REGISTRY\":{\"username\":\"$CI_REGISTRY_USER\",\"password\":\"$CI_REGISTRY_PASSWORD\"}}}" > /kaniko/.docker/config.json + - /kaniko/executor --cache=true --context $CI_PROJECT_DIR --dockerfile ./Dockerfile --destination $CI_REGISTRY_IMAGE:latest + tags: + - docker + + ###### Test jobs ##### .test:meson: &conan_def + stage: test + image: $CI_REGISTRY_IMAGE:latest + needs: ['build-img'] script: - - python -m pip install conan - conan create . -s build_type=$BUILD_TYPE tags: - - mfix-exa + - docker test:meson:debug: variables: @@ -21,14 +40,16 @@ test:meson:release: <<: *conan_def .test:cmake: &cmake_def + stage: test + image: $CI_REGISTRY_IMAGE:latest + needs: ['build-img'] script: - - python -m pip install cmake ninja conan - cmake -S. -Bbuild -GNinja -DCMAKE_BUILD_TYPE=$BUILD_TYPE - cmake --build build --target unit_tests_csg - cd build - ctest tags: - - mfix-exa + - docker test:cmake:debug: variables: diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..d7b8b13 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,11 @@ +# Docker Image for running csg-eb tests + +FROM python:3.8.6 + +MAINTAINER Mark Meredith + +RUN wget https://bootstrap.pypa.io/get-pip.py +RUN python3 get-pip.py +RUN python3 -m pip install cmake conan ninja + +CMD [ "/bin/bash" ] -- GitLab