Commit Graph

22 Commits

Author SHA1 Message Date
Jeremy Stanley 971387d3ae Change get-pip url
The path for get-pip.py script in version 3.5 has been changed
with this commit [1].

[1] https://github.com/pypa/get-pip/commit/2360f02

Co-Authored-By: daniel.pawlik <dpawlik@redhat.com>
Change-Id: Id127620ac5c3d7be8bb85bf2dc37bc77248d400c
2021-03-08 14:20:13 +00:00
Jeremy Stanley b29f4ab14d Pin get-pip.py to last Python 3.5 version
We only support Puppet versions available for platforms up through
Ubuntu Xenial, which provides Python 3.5 as its python3 interpreter.
Recently pip, and by extension get-pip.py, ceased supporting Python
<3.6 but added stable URLs for the last releases to support earlier
interpreters. Switch to the URL for a get-pip.py which will still
work for Xenial servers.

Also fix a couple of new linter failures.

Change-Id: I042bfc330e4d562313cf0dbf2be7d0e2d5779f40
2021-02-11 01:55:37 +00:00
Paul Belanger bd054ab0c0 Ensure curl is installed
Depends-On: I8b346cbfb908c5d2094c5e46ff008ef735b0e903
Depends-On: Icd0c652ff2f522ce2ea9086965f53e1a03f0d4fd
Depends-On: I17c119e81a035916550de44356b9f4badd505c81
Change-Id: Ia8e6bf0a0dd686933cd04a5e678d1f88ebdd8245
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-08-24 20:51:45 +00:00
Paul Belanger 47ec7c8e0c Switch incorrect symlink order
All this did was symlnk pip2 to pip, which became installed by python3
on our previous run.

We need to properly revert this on our production systems now.

Change-Id: Ie27c4476ecea9d0a29f40400bbc3bdbe704905a6
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-06-01 15:07:29 +02:00
Paul Belanger 35a83454f2
Add pip3 support
We are wanting to start running python3 applications in production, as
a results we need to ensure that pip3 is created.

Because get-pip.py will override existing pip executables, it will be
possible for an existing server to have is version change to python3.
As a result, symlink specifically to pip2 to ensure we have defaulted
properly to python3.

Drop Babel from acceptance testing, this appears to be a failure that
needs to be looked at in the future.

Change-Id: I8f78dfc62cd3745e900eec573e80236137ac5c78
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2017-05-31 14:39:00 -04:00
Dirk Mueller 4b3f7168ae Add support for Suse family
Change-Id: I92ac35151364c2390eddf2a8c71985049d3814c3
2017-02-24 14:04:28 +01:00
Colleen Murphy d5655ff4d1 Fix pip executable path for RH
get-pip.py installs pip to /bin/pip on centos 7. Without this fix, the
download-pip exec will keep trying to install pip whether or not it is
already installed on our base images or by puppet.

Change-Id: Ic5bcce59148aacedc61315e616317fc73c2c161c
2016-04-06 13:26:46 -07:00
Andrey Nikitin 63ef1497e2 Order of the class parameters is refactored
Order and intendation of those parameters are changed
to follow Puppet Style Guide recommendation [0].
Moreover, it will allow to an user to find much faster
a variable in a list of variables.

[0]. https://docs.puppetlabs.com/guides/style_guide.html

Change-Id: I1c319006878007d9d93a201a40c70843fa1bcf21
2016-03-21 18:08:19 +03:00
Jenkins 7959d3d4ca Merge "Allow to send optional values to configuration" 2015-10-09 13:39:16 +00:00
Ricardo Carrillo Cruz b34777a383 Fix the puppet-pip module to install pip
The class pip does not install pip, as one
would expect.
This fixes it.

Change-Id: I926cbfc1f65805c29a72597eede8c47228bdee30
2015-09-02 09:03:42 +00:00
Paul Belanger a0d714c7cf Add Gemfile and puppet 4 checks
In anticipation of puppet 4, start trying to deal with puppet 4 things
that can be helpfully predicted by puppet lint plugins.

Change-Id: I498052d2db57e571f0f91cd2c2e43e39c693331f
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2015-08-06 14:11:06 -04:00
Yolanda Robla 4906bf3178 Allow to send optional values to configuration
Under certain situations, is useful to send some
extra configuration to pip.conf, such as the retries,
timeout, etc...
This change allows to pass extra values as optional
settings to the template.

Change-Id: Ibcf431a17717fb7f8b8f501603f035fd9456def4
2015-08-03 17:29:58 +02:00
Yolanda Robla 754d3c1539 Add the ability to set pip.conf and configure it
Create an initial pip.conf file and allow passing
several settings such as index url and trusted
hosts.

Change-Id: I78962555c9a9ec1a96ce19810a463a5d619b04f9
2015-04-10 08:18:22 +02:00
Monty Taylor cb3ce4d802 Install pip using get-pip in launch node
packaged pip vs. upstream pip gets the systems very broken. Make launch-node
use get-pip to install pip as per:

http://www.pip-installer.org/en/latest/installing.html

Change-Id: Ice28b47d766c04b42462a7297911dc1a1abe5a77
2013-12-18 20:03:39 +00:00
Jeremy Stanley 004b738c35 No longer link pip to pip-python on Red Hat
* modules/pip/manifests/init.pp: Remove the symlink workaround for
older python-pip EPEL packages since current versions now provide
/usr/bin/pip directly instead of /usr/bin/pip-python. The latter has
been switched to a symlink itself, so without this change in Puppet
we get circular symlinks and no executable.

Change-Id: If09a9c2a511dcc9ae845833543e304f1459fdeb2
2013-08-06 23:45:46 +00:00
Jeremy Stanley 7eaa598916 Don't symlink pip on Fedora.
* modules/pip/manifests/init.pp: Fedora installs /usr/bin/pip and
thus doesn't need a symlink there like CentOS and RHEL do.

Change-Id: I2da3d5ed11db94da3ee2c3c7cae96c76e124dbd5
Reviewed-on: https://review.openstack.org/34081
Reviewed-by: Clark Boylan <clark.boylan@gmail.com>
Approved: James E. Blair <corvus@inaugust.com>
Reviewed-by: James E. Blair <corvus@inaugust.com>
Tested-by: Jenkins
2013-06-25 21:40:18 +00:00
Dan Prince f73260ecd8 Add pip::python3 module and pip3 provider.
Adds python3 support to our pip package. Also adds a custom version
of the pip package provider which can be used when installing
things w/ python3-pip is explicitly required. For example:

  package { 'tox',
    provider => pip3,
    require  => Class[pip::python3],
  }

Change-Id: I1b563c8f7e647dad3a134ef1f0ec5b45b63f8b71
Reviewed-on: https://review.openstack.org/32451
Reviewed-by: Jeremy Stanley <fungi@yuggoth.org>
Reviewed-by: James E. Blair <corvus@inaugust.com>
Approved: Clark Boylan <clark.boylan@gmail.com>
Reviewed-by: Clark Boylan <clark.boylan@gmail.com>
Tested-by: Jenkins
2013-06-24 21:54:56 +00:00
Jeremy Stanley c63516f503 The facter osfamily of Ubuntu is Debian.
Clean up facter osfamily matches to just use Debian, not Ubuntu.
This is manually tested and confirmed to at least be the case on
Oneiric, Precise and Quantal.

Change-Id: I27b184ac419910f9c3271c3b4e57886333282a5f
Reviewed-on: https://review.openstack.org/27399
Reviewed-by: Spencer Krum <krum.spencer@gmail.com>
Reviewed-by: Clark Boylan <clark.boylan@gmail.com>
Reviewed-by: James E. Blair <corvus@inaugust.com>
Approved: Jeremy Stanley <fungi@yuggoth.org>
Reviewed-by: Jeremy Stanley <fungi@yuggoth.org>
Tested-by: Jenkins
2013-04-25 21:37:00 +00:00
Jeremy Stanley 94496f8434 Jenkins slave puppetry for CentOS.
The install scripts now look for CentOS in release files. Also some
instances of facter's operatingsystem are switched to osfamily and
capitalization of RedHat is normalized to match what facter uses.

Change-Id: I3bbca5481d0d5e6de9e62bfd6e2b0a85264ed6ed
Reviewed-on: https://review.openstack.org/27398
Reviewed-by: Clark Boylan <clark.boylan@gmail.com>
Reviewed-by: James E. Blair <corvus@inaugust.com>
Approved: Jeremy Stanley <fungi@yuggoth.org>
Reviewed-by: Jeremy Stanley <fungi@yuggoth.org>
Tested-by: Jenkins
2013-04-25 21:36:58 +00:00
Dan Prince 2a7c4b3d83 Update pip module to support Red Hat distros.
Adds a new pip::params module where we set parameters based on
the operating system.

Updates the pip::init module so that it makes use of distro specific
parameters.

Also, includes a change to pip::init so that a soft link is
created for /usr/bin/pip (pointing to /usr/bin/pip-python). This
is required in order for the Puppet pip provider to work on Red Hat
distributions. Seems like we should push a fix into Puppet for this
as well but having this live here for now seems reasonable.

Change-Id: Ifee6bc42fabcf65ee1241ffac38f3bead7335be1
Reviewed-on: https://review.openstack.org/18904
Reviewed-by: Monty Taylor <mordred@inaugust.com>
Reviewed-by: Clark Boylan <clark.boylan@gmail.com>
Reviewed-by: Jeremy Stanley <fungi@yuggoth.org>
Reviewed-by: James E. Blair <corvus@inaugust.com>
Approved: James E. Blair <corvus@inaugust.com>
Tested-by: Jenkins
2013-01-17 18:24:16 +00:00
Paul Belanger b87063de9e Additional puppet-lint formatting
Change-Id: I6e5fa77a301eec30cff8e16bad33a91bfd95b13f
Signed-off-by: Paul Belanger <paul.belanger@polybeacon.com>
Reviewed-on: https://review.openstack.org/17176
Reviewed-by: Jeremy Stanley <fungi@yuggoth.org>
Reviewed-by: James E. Blair <corvus@inaugust.com>
Approved: Jeremy Stanley <fungi@yuggoth.org>
Tested-by: Jenkins
2012-11-30 20:56:32 +00:00
Monty Taylor c0c1a08acd Move python-pip include to a class.
You can't have two different classes install the same package (FAIL)
But you can have two different classes include the same class, so
by encapsulating the "install pip" code into a module, we can safely
consume it across multiple modules.

Sometimes I really hate puppet.

Change-Id: I3467c52b6887298c1b4d01a29873c63edf0adfd3
2012-07-23 15:43:27 -05:00