Commit Graph

4 Commits

Author SHA1 Message Date
Tobias Urdin a9322c04b6 Rework upload-forge role to use module
Renames the role to upload-forge because you can actually
run your own Forge server if you want.

This patch adds a custom module to the upload-forge
role that provides the "forge_upload" module.

This directly interacts with the a Forge API to upload the
module. The only dependency is that the python requests
module is installed.

Change-Id: I5749364bd2c29ad6df866c2bd5a3584c8419f709
2019-02-09 10:32:34 +01:00
Tobias Urdin db1629dc97 Use become for packages in upload-puppetforge
The upload-puppetforge role when executed as a
unprivileged user fails to install system packages
and the gems in the system gem home, see failure [1].

This adds become to the calls so that it becomes the
privileged user and executes these which will make them
have system access like the bindep role [2].

[1] http://logs.openstack.org/61/617ffad84b633618490ca1023f8a31d9694b31a9/release/release-openstack-puppet/c6e519d/job-output.txt.gz#_2019-01-21_20_53_17_207155
[2] https://git.openstack.org/cgit/openstack-infra/zuul-jobs/tree/roles/bindep/tasks/packages.yaml#n6

Change-Id: I4f11319727a4a5694f11abad4ded69ee554326f2
2019-01-21 22:14:35 +01:00
Tobias Urdin fd8ffc6711 Fix upload-puppetforge role
The role failed because the puppet-blacksmith gem required
ruby-dev, gcc/g++ compiler and make to compile the gems that
had native extensions.

Fixes the Rakefile since the puppet-blacksmith module
requires a "build" rake task, we can just empty that out
since this role assumed the pkg/ folder in the module
(zuul project dir) already contains the built module.

Setups the GEM_HOME and GEM_BIN folders correctly so that
we install gems in a predictable path which we can then
pass as an environment to the rake command so that it
knows where the actual commands are stored.

Change-Id: I2b39dd69ab56d51e169b7ac6b77c675646006f10
2019-01-17 10:16:22 +01:00
Tobias Urdin 20583c1e77 Add upload-puppetforge role
Adds a new role that can be used to upload a
built puppet module tarball to forge.puppet.com

Change-Id: I16c4da93592dc92b84ff8ad9540c75c7d3b39a91
2019-01-14 12:30:00 +01:00