summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPaul Belanger <pabelanger@redhat.com>2017-08-24 12:39:48 -0400
committerClark Boylan <cboylan@sapwetik.org>2017-08-24 20:51:45 +0000
commitbd054ab0c093b03adf4a8cc8bb26e5abfca9c859 (patch)
tree052eb365f6b7888d33646f1f75ce2087a951f980
parent44090680a93a5515cb80e8d1b1b242f6637e2fa2 (diff)
Ensure curl is installed
Notes
Notes (review): Code-Review+2: James E. Blair <corvus@inaugust.com> Code-Review+2: Clark Boylan <cboylan@sapwetik.org> Workflow+1: Clark Boylan <cboylan@sapwetik.org> Verified+2: Jenkins Submitted-by: Jenkins Submitted-at: Fri, 25 Aug 2017 01:12:18 +0000 Reviewed-on: https://review.openstack.org/497484 Project: openstack-infra/puppet-pip Branch: refs/heads/master
-rw-r--r--manifests/init.pp11
1 files changed, 9 insertions, 2 deletions
diff --git a/manifests/init.pp b/manifests/init.pp
index be190d8..786eb5c 100644
--- a/manifests/init.pp
+++ b/manifests/init.pp
@@ -12,20 +12,27 @@ class pip (
12 package { $::pip::params::python_devel_package: 12 package { $::pip::params::python_devel_package:
13 ensure => present, 13 ensure => present,
14 } 14 }
15 if !defined(Package['curl']) {
16 package { 'curl':
17 ensure => present,
18 }
19 }
15 20
16 if $::operatingsystem != 'CentOS' { 21 if $::operatingsystem != 'CentOS' {
17 exec { 'download-pip3': 22 exec { 'download-pip3':
18 command => "/usr/bin/curl ${::pip::params::get_pip_location} | /usr/bin/python3 - -U --force-reinstall", 23 command => "/usr/bin/curl ${::pip::params::get_pip_location} | /usr/bin/python3 - -U --force-reinstall",
19 creates => $::pip::params::get_pip3_path, 24 creates => $::pip::params::get_pip3_path,
20 before => Exec['download-pip'], 25 before => Exec['download-pip'],
21 notify => Exec[$::pip::params::get_pip_path] 26 notify => Exec[$::pip::params::get_pip_path],
27 require => Package['curl'],
22 } 28 }
23 } 29 }
24 30
25 exec { 'download-pip': 31 exec { 'download-pip':
26 command => "/usr/bin/curl ${::pip::params::get_pip_location} | /usr/bin/python - -U --force-reinstall", 32 command => "/usr/bin/curl ${::pip::params::get_pip_location} | /usr/bin/python - -U --force-reinstall",
27 creates => $::pip::params::get_pip2_path, 33 creates => $::pip::params::get_pip2_path,
28 notify => Exec[$::pip::params::get_pip_path] 34 notify => Exec[$::pip::params::get_pip_path],
35 require => Package['curl'],
29 } 36 }
30 37
31 # NOTE(pabelanger): Default to pip2 for backwards compat 38 # NOTE(pabelanger): Default to pip2 for backwards compat