aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--files/ondrej_ubuntu_php.gpgbin0 -> 364 bytes
-rw-r--r--manifests/series5/packages/dpa.pp2
-rw-r--r--manifests/series5/packages/ppa.pp26
3 files changed, 26 insertions, 2 deletions
diff --git a/files/ondrej_ubuntu_php.gpg b/files/ondrej_ubuntu_php.gpg
new file mode 100644
index 0000000..04c5d9b
--- /dev/null
+++ b/files/ondrej_ubuntu_php.gpg
Binary files differ
diff --git a/manifests/series5/packages/dpa.pp b/manifests/series5/packages/dpa.pp
index bff8bd1..297c4a2 100644
--- a/manifests/series5/packages/dpa.pp
+++ b/manifests/series5/packages/dpa.pp
@@ -7,7 +7,7 @@ class php::series5::packages::dpa {
source => 'puppet:///modules/php/deb.sury.org.gpg',
}
- file { '/etc/apt/sources.list.d/php.list' :
+ file { '/etc/apt/sources.list.d/php.list':
ensure => present,
owner => "root",
group => "root",
diff --git a/manifests/series5/packages/ppa.pp b/manifests/series5/packages/ppa.pp
index 10c5b56..e420822 100644
--- a/manifests/series5/packages/ppa.pp
+++ b/manifests/series5/packages/ppa.pp
@@ -3,7 +3,7 @@ class php::series5::packages::ppa {
# ensure => present,
#}
- ## TODO: check repository key!
+ # This required alternative checking of repository key!
#exec { 'add-apt-repository-ondrej-php':
# command => '/usr/bin/add-apt-repository -y ppa:ondrej/php && apt-get update',
# user => 'root',
@@ -11,6 +11,30 @@ class php::series5::packages::ppa {
# require => Package['python-software-properties'],
#}
+ file { '/etc/apt/trusted.gpg.d/ondrej_ubuntu_php.gpg':
+ ensure => present,
+ owner => "root",
+ group => "root",
+ mode => "0644",
+ source => 'puppet:///modules/php/ondrej_ubuntu_php.gpg',
+ }
+
+ file { '/etc/apt/sources.list.d/php.list':
+ ensure => present,
+ owner => "root",
+ group => "root",
+ mode => "0644",
+ content => "deb http://ppa.launchpad.net/ondrej/php/ubuntu ${::lsbdistcodename} main\n",
+ require => File['/etc/apt/trusted.gpg.d/ondrej_ubuntu_php.gpg'],
+ notify => Exec['php-apt-auto-update'],
+ }
+
+ exec { 'php-apt-auto-update':
+ command => "/usr/bin/apt-get update",
+ user => "root",
+ refreshonly => true,
+ }
+
# The needed packages: we could also try libapache2-mod-php5.6filter
package { 'php5':
name => 'php5.6',