Skip to content
Snippets Groups Projects
Commit 3582bbf0 authored by Nico's avatar Nico
Browse files

Merge branch 'nrbffs/ci-set-branch' into 'master'

CI: set GLUON_BRANCH depending on build type

See merge request freifunk-region/stuttgart/site!3
parents eb1398ec 54e9c0b9
No related branches found
No related tags found
No related merge requests found
......@@ -19,7 +19,7 @@ stages:
stage: build
script:
- make -C gluon update GLUON_SITEDIR="$CI_PROJECT_DIR"
- make -C gluon GLUON_SITEDIR="$CI_PROJECT_DIR" GLUON_TARGET="$GLUON_TARGET" GLUON_BRANCH=nightly V=1 -j`nproc`
- make -C gluon GLUON_SITEDIR="$CI_PROJECT_DIR" GLUON_TARGET="$GLUON_TARGET" GLUON_BRANCH=$(./get-gluon-branch.sh) V=1 -j`nproc`
artifacts:
paths:
- gluon/output/
......@@ -132,8 +132,9 @@ target:x86-64:
package:
stage: package
script:
- make -C gluon update GLUON_SITEDIR="$CI_PROJECT_DIR"
- make -C gluon manifest GLUON_BRANCH=nightly GLUON_SITEDIR="$CI_PROJECT_DIR" V=1
- GLUON_BRANCH=$(./get-gluon-branch.sh)
- test -z "$GLUON_BRANCH" || make -C gluon update GLUON_SITEDIR="$CI_PROJECT_DIR"
- test -z "$GLUON_BRANCH" || make -C gluon manifest GLUON_BRANCH=$(./get-gluon-branch.sh) GLUON_SITEDIR="$CI_PROJECT_DIR" V=1
artifacts:
paths:
- gluon/output
......
#!/bin/bash
set -eu
set -o pipefail
# autoupdater
# ====
#
# For commit builds, the autoupdater shall be off, i.e. GLUON_BRANCH unset.
# For nightly, GLUON_BRANCH must be nightly.
# For beta, GLUON_BRANCH must be beta.
# For stable, GLUON_BRANCH must be stable.
gluon_branch=""
if [[ "${CI_PIPELINE_SOURCE:-}" = "schedule" ]]; then
gluon_branch="nightly"
fi
case "${CI_COMMIT_TAG:-}" in
beta/*)
gluon_branch="beta"
;;
stable/*)
gluon_branch="stable"
;;
esac
# Else: Commit build
echo $gluon_branch
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment