diff --git a/docs/rolereference.rst b/docs/rolereference.rst index c097259fa0f02cb4bf7158eaba635f14b8e6ce46..6de6d32ad5a792c96d6ab8f811caa85c1a7d413b 100644 --- a/docs/rolereference.rst +++ b/docs/rolereference.rst @@ -478,6 +478,7 @@ Distribution compatibility Role is compatible with the following distributions: - Debian 11 (Bullseye) +- Debian 12 (Bookworm) Examples diff --git a/roles/common/meta/main.yml b/roles/common/meta/main.yml index c73a6fa97a74eb0ba5e19f7db0c8eaddad2d7527..c288bb5a4ea6523f3c3a739f9187ae3f6177b65a 100644 --- a/roles/common/meta/main.yml +++ b/roles/common/meta/main.yml @@ -23,3 +23,4 @@ galaxy_info: - name: Debian versions: - 11 + - 12 diff --git a/roles/common/molecule/default/molecule.yml b/roles/common/molecule/default/molecule.yml index 03df9bbfcaf37a8b91ae93f4a944b4772d9803a9..b8df3f40f471b71d135580a54524923ec794fa9e 100644 --- a/roles/common/molecule/default/molecule.yml +++ b/roles/common/molecule/default/molecule.yml @@ -14,7 +14,7 @@ lint: platforms: - name: helper - box: debian/bullseye64 + box: debian/bookworm64 memory: 512 cpus: 1 provider_raw_config_args: @@ -34,7 +34,7 @@ platforms: groups: - client - client-allowed - box: debian/bullseye64 + box: debian/bookworm64 memory: 256 cpus: 1 provider_raw_config_args: @@ -54,7 +54,7 @@ platforms: groups: - client - client-disallowed - box: debian/bullseye64 + box: debian/bookworm64 memory: 256 cpus: 1 provider_raw_config_args: @@ -108,6 +108,44 @@ platforms: netmask: 116 type: static + - name: parameters-mandatory-bookworm + groups: + - parameters-mandatory + box: debian/bookworm64 + memory: 384 + cpus: 1 + provider_raw_config_args: + - "customize ['modifyvm', :id, '--paravirtprovider', 'minimal']" + interfaces: + - auto_config: true + ip: 192.168.56.21 + network_name: private_network + type: static + - auto_config: true + ip: fd00::192:168:56:21 + network_name: private_network + netmask: 116 + type: static + + - name: parameters-optional-bookworm + groups: + - parameters-optional + box: debian/bookworm64 + memory: 384 + cpus: 1 + provider_raw_config_args: + - "customize ['modifyvm', :id, '--paravirtprovider', 'minimal']" + interfaces: + - auto_config: true + ip: 192.168.56.22 + network_name: private_network + type: static + - auto_config: true + ip: fd00::192:168:56:22 + network_name: private_network + netmask: 116 + type: static + provisioner: name: ansible playbooks: diff --git a/roles/common/molecule/default/prepare.yml b/roles/common/molecule/default/prepare.yml index 54f2f59d3d2ccf2fce93cc6fcd3a1bb4141c54bd..34e8b1a28659494f3743a480b5a469e6a2a68f98 100644 --- a/roles/common/molecule/default/prepare.yml +++ b/roles/common/molecule/default/prepare.yml @@ -74,6 +74,10 @@ 192.168.56.32: parameters-optional-bullseye fd00::192:168:56:31: parameters-mandatory-bullseye fd00::192:168:56:32: parameters-optional-bullseye + 192.168.56.21: parameters-mandatory-bookworm + 192.168.56.22: parameters-optional-bookworm + fd00::192:168:56:21: parameters-mandatory-bookworm + fd00::192:168:56:22: parameters-optional-bookworm - hosts: parameters-mandatory,parameters-optional become: true diff --git a/roles/common/tasks/main.yml b/roles/common/tasks/main.yml index 087d24d721560eba4716dd80d1da9ee140f5477b..d4afc69d9871d96d8966582e8bd4a99145df2839 100644 --- a/roles/common/tasks/main.yml +++ b/roles/common/tasks/main.yml @@ -61,7 +61,7 @@ dest: "/etc/adduser.conf" state: present backrefs: true - regexp: '^DIR_MODE=' + regexp: '^\s*#?\s*DIR_MODE=' line: 'DIR_MODE=0750' - name: Deploy bash profile configuration for fancier prompts @@ -103,7 +103,7 @@ owner: root group: root mode: 0640 - # Checksums: bullseye + # Checksums: bullseye and bookworm (same) when: | root_bashrc_stat.stat.checksum == "1a422a148ad225aa5ba33f8dafd2b7cfcdbd701f" @@ -483,6 +483,15 @@ state: present when: ntp_pools | length > 0 +- name: Remove NTP packages + apt: + name: + - ntpsec + - ntpsec-ntpdate + state: absent + purge: true + when: ntp_pools | length == 0 + - name: Deploy NTP configuration template: src: "ntp.conf.j2"