diff options
authorintrigeri <>2019-05-19 05:19:30 +0000
committerintrigeri <>2019-05-19 05:19:45 +0000
commit26f636bdd4455d398466d172ac89e794f2853217 (patch)
parent66b67bd21baed5087cae0530773370da46c83b97 (diff)
Revert "Build system: try to be smart again by fetching only the refs we need."
This optimization overrides the trick we have on Jenkins (set_origin_base_branch_head in, that ensures that a reproducibly_build_Tails_ISO_* job builds from the commit used by the first build. This reverts commit 6093f369a00a95bc8705aef31a10f918996f5fc3. Refs: #16730
1 files changed, 2 insertions, 16 deletions
diff --git a/vagrant/provision/assets/build-tails b/vagrant/provision/assets/build-tails
index 1a0d083..cabbc0b 100755
--- a/vagrant/provision/assets/build-tails
+++ b/vagrant/provision/assets/build-tails
@@ -92,22 +92,8 @@ cd "${TAILS_GIT_DIR}"
# option is set) later in auto/build.
git config remote.origin.fetch +refs/remotes/origin/*:refs/remotes/origin/*
-# Ensure we have the Git refs we need:
-git fetch origin "${GIT_REF}"
-# The repo we cloned above (the host's repo) will expose *its* local
-# checkouts of branches. We know that the GIT_REF ref will be
-# up-to-date since it is what is checked out on the host, so we could
-# just fetch it above, but for any other ref (read: branch) the local
-# checkout could be very out-of-date, or worse: it may not even exist,
-# making any attempt at merging the base branch below fail. We work
-# around this by fetching the ref from the host's origin (most likely
-# the official Tails repo) where the base branch refs must exist and
-# be as up-to-date as possible (i.e. since the host's last fetch).
-if [ "${TAILS_MERGE_BASE_BRANCH}" = 1 ]; then
- git fetch origin "origin/$(cat config/base_branch)"
-# Ensure we have the same Git state as on the host:
+# Ensure we have the same Git state as on the host
+git fetch --tags
git checkout --force "${GIT_REF}"
git reset --hard "${GIT_COMMIT}"
git submodule update --init