diff options
author | Silvio Rhatto <rhatto@riseup.net> | 2024-12-31 18:22:12 -0300 |
---|---|---|
committer | Silvio Rhatto <rhatto@riseup.net> | 2024-12-31 18:22:12 -0300 |
commit | 74d515930abbf2278ac4387cb16f5f2ce5f08807 (patch) | |
tree | fcdbcc4e91991225ef06c144602c81f37839313e /manifests/dpa.pp | |
parent | a344dbf14ca118ea4862f171d2111713607e54c6 (diff) | |
download | puppet-php-74d515930abbf2278ac4387cb16f5f2ce5f08807.tar.gz puppet-php-74d515930abbf2278ac4387cb16f5f2ce5f08807.tar.bz2 |
Diffstat (limited to 'manifests/dpa.pp')
-rw-r--r-- | manifests/dpa.pp | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/manifests/dpa.pp b/manifests/dpa.pp index d159b36..26cdf69 100644 --- a/manifests/dpa.pp +++ b/manifests/dpa.pp @@ -1,4 +1,12 @@ -class php::dpa inherits php::repository { +class php::dpa( + $ensure = 'present', +) { + class { 'php::repository': + ensure => $ensure, + content => "deb [signed-by=/etc/apt/keyrings/deb.sury.org-php.gpg] https://packages.sury.org/php/ ${::lsbdistcodename} main\n", + dependencies => File['/etc/apt/keyrings/deb.sury.org-php.gpg'], + } + # Old location file { '/etc/apt/trusted.gpg.d/deb.sury.org-php.gpg': ensure => absent, @@ -9,22 +17,17 @@ class php::dpa inherits php::repository { } file { '/etc/apt/keyrings/deb.sury.org-php.gpg': - ensure => present, + ensure => $ensure, owner => "root", group => "root", mode => "0644", source => 'puppet:///modules/php/deb.sury.org.gpg', } - File['/etc/apt/sources.list.d/php.list'] { - content => "deb [signed-by=/etc/apt/keyrings/deb.sury.org-php.gpg] https://packages.sury.org/php/ ${::lsbdistcodename} main\n", - require => File['/etc/apt/keyrings/deb.sury.org-php.gpg'], - } - # Pinning # Adapted from https://dmvrtx.me/2023/06/php-7.4-on-debian-bookworm/ file { '/etc/apt/preferences.d/php': - ensure => present, + ensure => $ensure, owner => "root", group => "root", mode => "0644", |