Commit 9676fb33 authored by Marius DAVID's avatar Marius DAVID
Browse files

Merge branch 'better_ci_caching' into 'main'

Use gitlab-ci-nix that should provide a cache

See merge request marius851000/fediverse-canvas-atlas-2024!356
parents 29646068 dacbf2c2
Loading
Loading
Loading
Loading
Loading
+5 −2
Original line number Diff line number Diff line
# See https://gitlab.com/gitlab-org/gitlab/-/blob/master/lib/gitlab/ci/templates/Python.gitlab-ci.yml

image: nixos/nix
include:
    - 'https://gitlab.com/Cynerd/gitlab-ci-nix/-/raw/master/template.yml'

stages:
  - build
@@ -10,8 +11,9 @@ variables:
  NIX_CACHE_HOME: "./nix-cache"

build:
  extends: .nix
  rules:
    - if: $CI_PIPELINE_SOURCE == $CI_PIPELINE_SOURCE # Truly terrible syntax (otherwise, won’t run during MR as a side effect of the rule in comment-link )
    - if: $CI_PIPELINE_SOURCE == $CI_PIPELINE_SOURCE # Truly terrible syntax (otherwise, won’t run during MR as a side effect of the rule in comment )
  stage: "build"
  cache:
    key: nix-user-cache
@@ -29,6 +31,7 @@ build:
      - "atlas2025.json"

comment:
  extends: .nix
  stage: "comment"
  rules:
    - if: "$CI_PIPELINE_SOURCE == 'merge_request_event'"