From c2600e92f9f92760b3e313646bc7f1325f4ef6a3 2025-02-15 20:15:03 From: Branko Majic Date: 2025-02-15 20:15:03 Subject: [PATCH] MAR-245: Upgrade to Ansible 11.2.x: - Update the requirements files. - Update documentation. - Update role meta information. - No obvious breakages at the moment. --- diff --git a/docs/index.rst b/docs/index.rst index 1614e1ed0645a0d36f91669d35b1b082f4c3cd8f..76a83af75862dad0ae974402fb65849d5ba8f7a1 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -14,8 +14,8 @@ installations. Roles are written for use with *Debian GNU/Linux*. For more details on supported releases, see :ref:`rolereference`. -At the moment, the roles have been written for and tested against **Ansible -10.4.x**. +At the moment, the roles have been written for and tested against +**Ansible 11.2.x**. The roles also utilise the ``ipv4/ipv6`` lookup plugins which require ``netaddr`` package to be installed. The ``passlib`` package is used diff --git a/docs/releasenotes.rst b/docs/releasenotes.rst index 411a2c20529fe7993e57553250363e4e25a7f800..ba801be054b958991fc943bb8efe78bf9a25a42e 100644 --- a/docs/releasenotes.rst +++ b/docs/releasenotes.rst @@ -5,14 +5,14 @@ Release notes x.y.z ----- -Upgraded to Ansible 10.4.x. Dropped support for Debian 11 +Upgraded to Ansible 11.2.x. Dropped support for Debian 11 (Bullseye). Minor fixes and improvements. **Breaking changes:** * All roles - * Upgraded to Ansible 10.4.x. + * Upgraded to Ansible 11.2.x. * Dropped support for Debian 11 (Bullseye). * ``passlib`` Python package is now (explicitly) required for using the roles. diff --git a/docs/usage.rst b/docs/usage.rst index 3545f29d7138b9265d660bf86d9ca4eeebd19fe1..174fdaf6116e9d532d1d87d2a22fcdf62ec0ac00 100644 --- a/docs/usage.rst +++ b/docs/usage.rst @@ -135,7 +135,7 @@ packages, and to prepare the environment a bit on the Ansible server: mkdir ~/mysite/ mkvirtualenv -a ~/mysite/ mysite pip install -U pip setuptools - pip install 'ansible~=10.4.0' netaddr passlib + pip install 'ansible~=11.2.0' netaddr passlib .. warning:: The ``netaddr`` package is needed for ``ipv4/ipv6`` lookup plugins diff --git a/requirements.in b/requirements.in index e9cc510064ff72bf0133ee470f92e91c449079e6..2880a2bfd5b58ffb2ef5c34a2253db871d64bf96 100644 --- a/requirements.in +++ b/requirements.in @@ -1,5 +1,5 @@ # Ansible and role runtime. -ansible~=10.4.0 +ansible~=11.2.0 netaddr passlib python-ldap @@ -9,8 +9,24 @@ ansible-lint defusedxml flake8 gimmecert -molecule[testinfra]~=24.8.0 -molecule-plugins[vagrant]~=23.5.0 +# @WORKAROUND: Newer versions of Molecule break with Vagrant backend +# Due to introduction of more invasive changes (in 25.2.0), +# running newer versions of Molecule in combination with Vagrant +# is broken. For more details, see: +# +# - https://github.com/ansible-community/molecule-plugins/issues/301 +# +# Additional issue is that the ephemeral directory location has +# changed, which may cause some issues with the mail_server role +# testing. The ephemeral directory is currently used to store the +# ClamAV database files in order to avoid getting blocked by the +# upstream because of hitting the rate limit. When Molecule does get +# upgraded eventually, it might be worth it to also look into +# splitting out this ClamAV database cache explicitly into some +# directory like ~/.cache/majic-ansible-roles-clamavdb instead of +# relying on the Molecule ephemeral directory. +molecule[testinfra]~=25.1.0 +molecule-plugins[vagrant]~=23.7.0 paramiko pytest-env diff --git a/requirements.txt b/requirements.txt index 7500d67212157b96433b88e90eeb5f4fca6661a8..a99c622c31d680699c9f82c91bbfb15cc2293bd1 100644 --- a/requirements.txt +++ b/requirements.txt @@ -6,13 +6,13 @@ # alabaster==1.0.0 # via sphinx -ansible==10.4.0 +ansible==11.2.0 # via -r requirements.in ansible-compat==25.1.2 # via # ansible-lint # molecule -ansible-core==2.17.8 +ansible-core==2.18.2 # via # ansible # ansible-compat @@ -97,11 +97,11 @@ mccabe==0.7.0 # via flake8 mdurl==0.1.2 # via markdown-it-py -molecule[testinfra]==24.8.0 +molecule[testinfra]==25.1.0 # via # -r requirements.in # molecule-plugins -molecule-plugins[vagrant]==23.5.3 +molecule-plugins[vagrant]==23.7.0 # via -r requirements.in mypy-extensions==1.0.0 # via black diff --git a/roles/backup/meta/main.yml b/roles/backup/meta/main.yml index dd09c32783966d34aaac090ef8d4091257d0f9de..8ecf1cbaac05587eda3f72945036c3b4447ad4d4 100644 --- a/roles/backup/meta/main.yml +++ b/roles/backup/meta/main.yml @@ -11,7 +11,7 @@ galaxy_info: author: Branko Majic description: Specify what files should be backed-up to the backup server. license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/backup_client/meta/main.yml b/roles/backup_client/meta/main.yml index f634405c04c27f5640a9654c7002d2b19940dba0..b171192e3163b9e60b562451f34ace0aab6d7558 100644 --- a/roles/backup_client/meta/main.yml +++ b/roles/backup_client/meta/main.yml @@ -6,7 +6,7 @@ galaxy_info: author: Branko Majic description: Sets-up backup client (using duplicity/duply) license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/backup_server/meta/main.yml b/roles/backup_server/meta/main.yml index a1affa4be0eb0a333bdde5b465e7d308c67f28cf..3b3f7e6daf8f77094ef489012ba2884cc4752d13 100644 --- a/roles/backup_server/meta/main.yml +++ b/roles/backup_server/meta/main.yml @@ -9,7 +9,7 @@ galaxy_info: author: Branko Majic description: Sets-up server to act as backup storage for the backup clients, exposing SFTP on dedicated port with dedicated OpenSSH server instance license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/bootstrap/meta/main.yml b/roles/bootstrap/meta/main.yml index e260c22981603a75e84e9cd77a25cd513e972445..06a870447c65f533c44efc092c3ea7c74b9d7ace 100644 --- a/roles/bootstrap/meta/main.yml +++ b/roles/bootstrap/meta/main.yml @@ -6,7 +6,7 @@ galaxy_info: author: Branko Majic description: Performs basic bootstrap of server for use with Ansible license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/common/meta/main.yml b/roles/common/meta/main.yml index 9d4c1730a97d8b8cf204576f95163c91a93e3dbe..f3edfb63932b04039bcf766b892caad4bde588e6 100644 --- a/roles/common/meta/main.yml +++ b/roles/common/meta/main.yml @@ -20,7 +20,7 @@ galaxy_info: author: Branko Majic description: Apply common configuration and hardening on server license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/database/meta/main.yml b/roles/database/meta/main.yml index 2dba93e1588f6fe9ae77b66042b645621784baa9..e08a4c79167bd466c2c97bb7dd86c41d3bff15bd 100644 --- a/roles/database/meta/main.yml +++ b/roles/database/meta/main.yml @@ -16,7 +16,7 @@ galaxy_info: author: Branko Majic description: Creates MariaDB database and accompanying user to access it license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/database_server/meta/main.yml b/roles/database_server/meta/main.yml index cb3cd35a1bdcb0abc4b0cb530d76fcbb2a3a973a..61c857044dddf3f6f2c98b24750ca698889bc5e3 100644 --- a/roles/database_server/meta/main.yml +++ b/roles/database_server/meta/main.yml @@ -9,7 +9,7 @@ galaxy_info: author: Branko Majic description: Sets-up MariaDB database server license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/ldap_client/meta/main.yml b/roles/ldap_client/meta/main.yml index e5f36db41f9ec6d0739ae19eadfdb4aa807e0aa5..693ec00e17dae6a022c163ecab3363a46cbfde62 100644 --- a/roles/ldap_client/meta/main.yml +++ b/roles/ldap_client/meta/main.yml @@ -6,7 +6,7 @@ galaxy_info: author: Branko Majic description: Configures OpenLDAP client (default configuration) license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/ldap_server/meta/main.yml b/roles/ldap_server/meta/main.yml index d2c07b55a744a2a810762ec7fe2c5f262de46bed..e52b9669df85afee0ecb5760fe0a94da0e770948 100644 --- a/roles/ldap_server/meta/main.yml +++ b/roles/ldap_server/meta/main.yml @@ -15,7 +15,7 @@ galaxy_info: author: Branko Majic description: Sets-up an OpenLDAP server license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/mail_forwarder/meta/main.yml b/roles/mail_forwarder/meta/main.yml index 0e3631c0b3dff1146e8a2ebba109f1381c40af7f..d693149c660ee73021322d7f21b1721a8a552467 100644 --- a/roles/mail_forwarder/meta/main.yml +++ b/roles/mail_forwarder/meta/main.yml @@ -9,7 +9,7 @@ galaxy_info: author: Branko Majic description: Sets-up local SMTP server for sending out mails and receiving mails for local users license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/mail_server/meta/main.yml b/roles/mail_server/meta/main.yml index 0e5eb061ea3482d40c42495da9c00cbdc8d853c1..9b176fe46fceb403483b7961c85d6f4c7018f3ba 100644 --- a/roles/mail_server/meta/main.yml +++ b/roles/mail_server/meta/main.yml @@ -14,7 +14,7 @@ galaxy_info: author: Branko Majic description: Sets-up mail server with SMTP and IMAP services, using LDAP as source of allowed destinations (domains, mail addresses) license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/php_website/meta/main.yml b/roles/php_website/meta/main.yml index daab7df4bc3b2e7bd2ee5b5924617747218582be..3d608331fba01d0dbec6812563a623229b9fc3c3 100644 --- a/roles/php_website/meta/main.yml +++ b/roles/php_website/meta/main.yml @@ -12,7 +12,7 @@ galaxy_info: author: Branko Majic description: Sets-up a website powered by PHP application license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/preseed/meta/main.yml b/roles/preseed/meta/main.yml index 6261b732c0b350fee34da5fece1f1b4e28958779..29a425eb22f90ba785efb9b26ea0ac689233ca48 100644 --- a/roles/preseed/meta/main.yml +++ b/roles/preseed/meta/main.yml @@ -6,7 +6,7 @@ galaxy_info: author: Branko Majic description: Generates preseed files for Debian license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/web_server/meta/main.yml b/roles/web_server/meta/main.yml index 4f338d80aa52713b8676fa095e7eb4cbfe0c65be..b283a9491af04de52e275a4f7651c5753d5f158f 100644 --- a/roles/web_server/meta/main.yml +++ b/roles/web_server/meta/main.yml @@ -9,7 +9,7 @@ galaxy_info: author: Branko Majic description: Sets-up generic web server license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/wsgi_website/meta/main.yml b/roles/wsgi_website/meta/main.yml index fc8bb899939e5140dc3a850c8873a354650dc239..b8e5ef50db4c834b7fb74f683954ec8c8d547e98 100644 --- a/roles/wsgi_website/meta/main.yml +++ b/roles/wsgi_website/meta/main.yml @@ -12,7 +12,7 @@ galaxy_info: author: Branko Majic description: Sets-up a website powered by WSGI application license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: diff --git a/roles/xmpp_server/meta/main.yml b/roles/xmpp_server/meta/main.yml index 3f0acb7667dc725cfaf1a6fa49c2c7394df51e42..4c8f3a710a2df80c822626cfe3438c6ac2935d53 100644 --- a/roles/xmpp_server/meta/main.yml +++ b/roles/xmpp_server/meta/main.yml @@ -14,7 +14,7 @@ galaxy_info: author: Branko Majic description: Sets-up a Prosody XMPP server using LDAP directory as source of domain/user information license: BSD - min_ansible_version: "10.4" + min_ansible_version: "11.2" platforms: - name: Debian versions: