Skip to content

Commit

Permalink
fix: switch the repository role over to using Packagecloud
Browse files Browse the repository at this point in the history
  • Loading branch information
natoscott committed Nov 22, 2023
1 parent 3e661d0 commit 85391aa
Show file tree
Hide file tree
Showing 7 changed files with 28 additions and 13 deletions.
2 changes: 1 addition & 1 deletion roles/repository/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# performancecopilot.metrics.repository

Installs and configures the upstream package repositories - currently hosted at [jFrog Artifactory](https://performancecopilot.jfrog.io/ui/builds) - to get the very latest [Performance Co-Pilot](https://pcp.io/) toolkit releases.
Installs and configures the upstream package repositories - currently hosted at [Packagecloud](https://packagecloud.io/performancecopilot/pcp) - to get the very latest [Performance Co-Pilot](https://pcp.io/) toolkit releases.

## Requirements

Expand Down
1 change: 0 additions & 1 deletion roles/repository/templates/artifactory.debs.j2

This file was deleted.

9 changes: 0 additions & 9 deletions roles/repository/templates/artifactory.rpms.j2

This file was deleted.

2 changes: 2 additions & 0 deletions roles/repository/templates/packagecloud.debs.j2
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
deb https://packagecloud.io/performancecopilot/pcp/{{ __repository_distro_name }} {{ ansible_distribution_release }} main
deb-src https://packagecloud.io/performancecopilot/pcp/{{ __repository_distro_name }} {{ ansible_distribution_release }} main
23 changes: 23 additions & 0 deletions roles/repository/templates/packagecloud.rpms.j2
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{{ ansible_managed | comment }}
{{ "performancecopilot:ansible-pcp" | comment(prefix="", postfix="") }}
[performancecopilot]
name=Performance Co-Pilot
baseurl=https://packagecloud.io/performancecopilot/pcp/{{ __repository_distro_name }}/$releasever/$basearch
repo_gpgcheck=1
enabled=1
gpgcheck=0
gpgkey=https://packagecloud.io/performancecopilot/pcp/gpgkey
sslverify=1
sslcacert=/etc/pki/tls/certs/ca-bundle.crt
metadata_expire=300

[performancecopilot-source]
name=Performance Co-Pilot source
baseurl=https://packagecloud.io/performancecopilot/pcp/{{ __repository_distro_name }}/$releasever/SRPMS
repo_gpgcheck=1
gpgcheck=0
enabled=1
gpgkey=https://packagecloud.io/performancecopilot/pcp/gpgkey
sslverify=1
sslcacert=/etc/pki/tls/certs/ca-bundle.crt
metadata_expire=300
2 changes: 1 addition & 1 deletion roles/repository/vars/Debian.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
---
# Put internal variables here with Debian specific values.

__repository_distro_name: "{{ ansible_facts['distribution_release'] }}"
__repository_distro_name: "{{ ansible_distribution|lower }}"

Check warning on line 5 in roles/repository/vars/Debian.yml

View workflow job for this annotation

GitHub Actions / ansible_lint

jinja[spacing]

Jinja2 spacing could be improved: {{ ansible_distribution|lower }} -> {{ ansible_distribution | lower }}
2 changes: 1 addition & 1 deletion roles/repository/vars/RedHat.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
---
# Put internal variables here with Red Hat specific values.

__repository_distro_name: "centos"
__repository_distro_name: "el"

0 comments on commit 85391aa

Please sign in to comment.