[gnome-build-meta/alatiera/push-master: 3/4] .gitlab-ci.yml: extract the cache configuration in a template
- From: Abderrahim Kitouni <akitouni src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-build-meta/alatiera/push-master: 3/4] .gitlab-ci.yml: extract the cache configuration in a template
- Date: Thu, 27 Sep 2018 20:10:40 +0000 (UTC)
commit 321a5cfe2b45f607af4e0f79db482d3825265a90
Author: Abderrahim Kitouni <akitouni gnome org>
Date: Thu Sep 27 20:18:49 2018 +0100
.gitlab-ci.yml: extract the cache configuration in a template
.gitlab-ci.yml | 24 +++++++++++-------------
1 file changed, 11 insertions(+), 13 deletions(-)
---
diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 9b76b68..dabe107 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -85,6 +85,15 @@ before_script:
fi
+.cache-template: &cache
+ # Store all the downloaded sources in the distributed cache. This saves
+ # us fetching them from the different repos and further afield
+ # on every build.
+ cache:
+ key: bst
+ paths:
+ - "${XDG_CACHE_HOME}/buildstream/sources/"
+
.build-template: &build
stage: build
script:
@@ -114,13 +123,7 @@ before_script:
ssh gbm-builder.gnome.org gbm-flatpak-scripts/import-commits -c "${CONFIG_FILE}"
incoming/repo-${CI_JOB_ID} ${BRANCHES}
fi
- # Store all the downloaded git and ostree repos in the distributed cache.
- # This saves us fetching them from the different repos and further afield
- # on every build.
- cache:
- key: bst
- paths:
- - "${XDG_CACHE_HOME}/buildstream/sources/"
+ <<: *cache
# Store artifacts so we can inspect build failures
artifacts:
when: always
@@ -135,12 +138,7 @@ track:
script:
- ${BST} track --deps all core.bst flatpak-runtimes.bst
- # Store all the downloaded sources in the distributed cache, so that later
- # jobs don't need to redownload them.
- cache:
- key: bst
- paths:
- - "${XDG_CACHE_HOME}/buildstream/sources/"
+ <<: *cache
# don't run on stable branches
except:
- /^gnome-\d-\d\d$/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]