depot/.gitlab-ci.yml
Luke Granger-Brown fe4b95c532 gitlab-ci: block parent pipeline until child is complete
Without strategy: depend, the parent pipeline will succeed immediately after
triggering the child.  It's more useful to mirror the status, so the commit
status is rendered correctly.
2021-03-28 15:30:15 +00:00

28 lines
631 B
YAML

# SPDX-FileCopyrightText: 2020 Luke Granger-Brown <depot@lukegb.com>
#
# SPDX-License-Identifier: Apache-2.0
stages:
- generate
- start
generatePipeline:
stage: generate
image: "nixos/nix:latest"
script:
- "nix build -v -f . nix.gitlab-ci --substituters \"https://cache.nixos.org/ s3://lukegb-nix-cache?endpoint=storage.googleapis.com&trusted=1\""
- "cat ./result > gitlab-ci.yml"
artifacts:
paths:
- gitlab-ci.yml
expire_in: '30 days'
tags:
- cacher
startPipeline:
stage: start
trigger:
strategy: depend
include:
- artifact: gitlab-ci.yml
job: generatePipeline