Ensure the build host is the first repo server

The first repo server is the only one configured to synchronise
packages to the other repo servers. To ensure that the build
happens on the first server, we reverse the order in which they
are processed in the loop.

This does not solve the multi-architecture use-case. A solution
for that will have to follow.

Change-Id: Ie6bd16ac08164f7dba71339858b98137f61ad716
This commit is contained in:
Jesse Pretorius 2019-04-12 17:49:13 +01:00 committed by Jesse Pretorius (odyssey4me)
parent afc6b9a4db
commit 0f4c3457e4
1 changed files with 1 additions and 1 deletions

View File

@ -69,7 +69,7 @@ venv_build_targets: |-
}
}
%}
{% for item in (groups['repo_all'] | default([inventory_hostname])) %}
{% for item in ((groups['repo_all'] | default([inventory_hostname])) | reverse) %}
{% set distro = hostvars[item]['ansible_distribution_version'] %}
{% set arch = hostvars[item]['ansible_architecture'] %}
{% set target_item = {(arch | string): (item | string)} %}