replace apt_repository with shell module

apt_repository use deprecated apt-key
This commit is contained in:
Oli
2023-02-28 01:52:50 +00:00
parent 34f3c54ceb
commit b9af96fbbe
2 changed files with 3 additions and 5 deletions

View File

@@ -1,9 +1,8 @@
---
- name: Add Sury PHP Repository
apt_repository:
repo: ppa:ondrej/php
state: present
update_cache: true
shell: add-apt-repository -y ppa:ondrej/php
args:
creates: "/etc/apt/sources.list.d/ondrej-ubuntu-php-jammy.list"
when: php_version is defined # add repo when version is specified, otherwise use default repo
- name: "Uninstall old PHP version"

View File

@@ -11,7 +11,6 @@
file:
path: "{{ hcloud_webserver_volume_path }}"
state: directory
mode: 0750
force: false
- name: Mount hcloud volume