@@ -74,15 +74,15 @@ stackhpc_apt_repositories:
74
74
# Do not replace apt configuration for non-overcloud hosts. This can result in
75
75
# errors if apt reconfiguration is performed before local repository mirrors
76
76
# are deployed.
77
- apt_repositories : " {{ stackhpc_apt_repositories | selectattr('required') | list if 'overcloud' in group_names else [] }}"
77
+ apt_repositories : " {{ stackhpc_apt_repositories | selectattr('required') | list if stackhpc_repos_enabled | bool else [] }}"
78
78
79
79
# Whether to disable repositories in /etc/apt/sources.list. This may be used
80
80
# when replacing the distribution repositories via apt_repositories.
81
81
# Default is false.
82
82
# Do not disable the default apt configuration for non-overcloud hosts. This
83
83
# can result in errors if apt reconfiguration is performed before local
84
84
# repository mirrors are deployed.
85
- apt_disable_sources_list : " {{ 'overcloud' in group_names }}"
85
+ apt_disable_sources_list : " {{ stackhpc_repos_enabled | bool }}"
86
86
87
87
# Apt auth configuration for accessing the package repository mirror.
88
88
stackhpc_apt_auth :
@@ -98,7 +98,7 @@ stackhpc_apt_auth:
98
98
# * filename: Name of a file in which to store the auth configuration. The
99
99
# extension should be '.conf'.
100
100
# Default is an empty list.
101
- apt_auth : " {{ stackhpc_apt_auth if 'overcloud' in group_names and stackhpc_repo_mirror_username is truthy else [] }}"
101
+ apt_auth : " {{ stackhpc_apt_auth if stackhpc_repos_enabled | bool and stackhpc_repo_mirror_username is truthy else [] }}"
102
102
103
103
# ##############################################################################
104
104
# Dummy variable to allow Ansible to accept this file.
0 commit comments