Fix pipeline attempt (4): Add new apptainer gitlab runner

This commit is contained in:
Kylian Schmidt
2025-09-08 15:49:09 +02:00
parent 30389ccb92
commit 412f5927fb
+6 -19
View File
@@ -18,13 +18,8 @@ cache:
# Build the Apptainer container # Build the Apptainer container
build:container: build:container:
stage: build stage: build
image: ubuntu:22.04 tags:
before_script: - apptainer
- apt-get update -qq
- apt-get install -y wget curl gpg
- wget -O /tmp/apptainer.deb https://github.com/apptainer/apptainer/releases/download/v1.2.5/apptainer_1.2.5_amd64.deb
- apt-get install -y /tmp/apptainer.deb
- mkdir -p $APPTAINER_CACHE_DIR
script: script:
- echo "Building Apptainer container..." - echo "Building Apptainer container..."
- apptainer --version - apptainer --version
@@ -38,14 +33,10 @@ build:container:
# Run tests inside the container # Run tests inside the container
test:pytest: test:pytest:
stage: test stage: test
image: ubuntu:22.04 tags:
- apptainer
dependencies: dependencies:
- build:container - build:container
before_script:
- apt-get update -qq
- apt-get install -y wget curl gpg
- wget -O /tmp/apptainer.deb https://github.com/apptainer/apptainer/releases/download/v1.2.5/apptainer_1.2.5_amd64.deb
- apt-get install -y /tmp/apptainer.deb
script: script:
- echo "Running pytest inside container..." - echo "Running pytest inside container..."
- apptainer exec $CONTAINER_IMAGE pytest /src/tests/ -v - apptainer exec $CONTAINER_IMAGE pytest /src/tests/ -v
@@ -55,14 +46,10 @@ test:pytest:
# Run tests with coverage # Run tests with coverage
test:coverage: test:coverage:
stage: test stage: test
image: ubuntu:22.04 tags:
- apptainer
dependencies: dependencies:
- build:container - build:container
before_script:
- apt-get update -qq
- apt-get install -y wget curl gpg
- wget -O /tmp/apptainer.deb https://github.com/apptainer/apptainer/releases/download/v1.2.5/apptainer_1.2.5_amd64.deb
- apt-get install -y /tmp/apptainer.deb
script: script:
- echo "Running coverage analysis inside container..." - echo "Running coverage analysis inside container..."
- apptainer exec $CONTAINER_IMAGE pytest /src/tests/ --cov=/src --cov-report=xml --cov-report=term - apptainer exec $CONTAINER_IMAGE pytest /src/tests/ --cov=/src --cov-report=xml --cov-report=term