diff --git a/defaults/main.yml b/defaults/main.yml index 16772c07..07e4bb2d 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -23,7 +23,7 @@ lxc_hosts_extra_distro_packages: [] # Define the total list of packages which to install onto the host combining # distibution specific and deployers extra package lists -lxc_hosts_distro_packages: "{{ _lxc_hosts_distro_packages + lxc_hosts_extra_distro_packages }}" +lxc_hosts_distro_packages: "{{ (_lxc_hosts_distro_packages | select) + lxc_hosts_extra_distro_packages }}" # Mappings from Ansible reported architecture to distro release architecture lxc_architecture_mapping: diff --git a/vars/debian-12.yml b/vars/debian-12.yml deleted file mode 100644 index 8d547fcb..00000000 --- a/vars/debian-12.yml +++ /dev/null @@ -1,59 +0,0 @@ ---- -# Copyright 2016, Rackspace US, Inc. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -_lxc_hosts_container_build_command: >- - debootstrap --variant minbase - --include ca-certificates - {{ ansible_facts['distribution_release'] }} - /var/lib/machines/{{ lxc_container_base_name }} - {{ lxc_apt_mirror }} - -_lxc_copy_from_host: - - /etc/apt/sources.list - - /etc/apt/sources.list.d/ - - /etc/apt/apt.conf.d/ - - /etc/apt/trusted.gpg.d/ - - /etc/apt/trusted.gpg - - /etc/apt/preferences.d/ - - /etc/apt/mirrors/ - - /etc/environment - - /etc/localtime - - /etc/protocols - -_lxc_cache_prep_template: "prep-scripts/debian_prep.sh.j2" - -_lxc_cache_distro_libpython: - bookworm: libpython3.11 - -# This list should contain a minimum set of packages. Add extra packages via roles that require them. -_lxc_cache_distro_packages: - - ca-certificates - - dbus - - git # needed everywhere when wheel_build=false - - iputils-ping - - iproute2 - - libxml2 - - locales - - netbase - - openssh-server - - python3 - - "{{ _lxc_cache_distro_libpython[ansible_facts['distribution_release'] | lower] }}" - - rsync # os_keystone runs serial=1 and uses rsync before the distro packages have been installed on all keystone targets - - sudo - - systemd - - systemd-sysv - - systemd-resolved - - tzdata - - udev diff --git a/vars/debian.yml b/vars/debian.yml index 51223e49..810d27bc 100644 --- a/vars/debian.yml +++ b/vars/debian.yml @@ -22,10 +22,12 @@ _lxc_hosts_container_build_command: >- _lxc_copy_from_host: - /etc/apt/sources.list + - /etc/apt/sources.list.d - /etc/apt/apt.conf.d/ - /etc/apt/trusted.gpg.d/ - /etc/apt/trusted.gpg - /etc/apt/preferences.d/ + - /etc/apt/mirrors - /etc/environment - /etc/localtime - /etc/protocols @@ -35,6 +37,7 @@ _lxc_cache_prep_template: "prep-scripts/debian_prep.sh.j2" _lxc_cache_distro_libpython: bullseye: libpython3.9 jammy: libpython3.10 + bookworm: libpython3.11 # This list should contain a minimum set of packages. Add extra packages via roles that require them. _lxc_cache_distro_packages: @@ -52,4 +55,6 @@ _lxc_cache_distro_packages: - sudo - systemd - systemd-sysv + - "{{ (ansible_facts['distribution'] == 'Debian') | ternary('systemd-resolved', '') }}" + - udev - tzdata