diff --git a/modules/gerrit/manifests/init.pp b/modules/gerrit/manifests/init.pp index cff9967d90..ac8109e600 100644 --- a/modules/gerrit/manifests/init.pp +++ b/modules/gerrit/manifests/init.pp @@ -146,10 +146,12 @@ class gerrit( ensure => present, } - package { 'gerritlib': - ensure => latest, - provider => 'pip', - require => Class[pip], + if ! defined(Package['gerritlib']) { + package { 'gerritlib': + ensure => latest, + provider => 'pip', + require => Class[pip], + } } file { '/var/log/gerrit': diff --git a/modules/jeepyb/manifests/init.pp b/modules/jeepyb/manifests/init.pp index dbce38745c..ec071a0bc0 100644 --- a/modules/jeepyb/manifests/init.pp +++ b/modules/jeepyb/manifests/init.pp @@ -4,12 +4,6 @@ class jeepyb ( $git_source_repo = 'https://github.com/openstack-ci/jeepyb.git', ) { - if ! defined(Package['python-mysqldb']) { - package { 'python-mysqldb': - ensure => present, - } - } - if ! defined(Package['python-paramiko']) { package { 'python-paramiko': ensure => present, @@ -52,6 +46,7 @@ class jeepyb ( cwd => '/opt/jeepyb', path => '/bin:/usr/bin', refreshonly => true, + require => Class['mysql::python'], subscribe => Vcsrepo['/opt/jeepyb'], }