Skip to content

Revert Pulp Squeezer version bump #1735

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: stackhpc/2025.1
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
74 changes: 62 additions & 12 deletions etc/kayobe/ansible/pulp-artifact-upload.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,18 @@
- urllib3
state: present

- name: Upload an artifact
pulp.squeezer.artifact:
pulp_url: "{{ remote_pulp_url }}"
username: "{{ remote_pulp_username }}"
password: "{{ remote_pulp_password }}"
file: "{{ found_files.files[0].path }}"
state: present
register: upload_result
until: upload_result is success
retries: 3
delay: 60

- name: Get sha256 hash
ansible.builtin.stat:
path: "{{ found_files.files[0].path }}"
Expand All @@ -46,49 +58,87 @@
checksum_algorithm: sha256
register: checksum_stats

- name: Ensure file repo exists
pulp.squeezer.file_repository:
- name: Upload checksum artifact
pulp.squeezer.artifact:
pulp_url: "{{ remote_pulp_url }}"
username: "{{ remote_pulp_username }}"
password: "{{ remote_pulp_password }}"
name: "{{ repository_name }}"
file: "/tmp/{{ found_files.files[0].path | basename }}.sha256"
state: present
register: file_repo_result
until: file_repo_result is success
register: checksum_upload_result
until: checksum_upload_result is success
retries: 3
delay: 5
delay: 60
when: upload_checksum

- name: Upload artifact
- name: Create file content from artifact
pulp.squeezer.file_content:
pulp_url: "{{ remote_pulp_url }}"
username: "{{ remote_pulp_username }}"
password: "{{ remote_pulp_password }}"
file: "{{ found_files.files[0].path }}"
sha256: "{{ file_stats.stat.checksum }}"
relative_path: "{{ found_files.files[0].path | basename }}"
state: present
repository: "{{ repository_name }}"
register: file_content_result
until: file_content_result is success
retries: 3
delay: 5

- name: Upload checksum
- name: Create checksum content from artifact
pulp.squeezer.file_content:
pulp_url: "{{ remote_pulp_url }}"
username: "{{ remote_pulp_username }}"
password: "{{ remote_pulp_password }}"
file: "/tmp/{{ found_files.files[0].path | basename }}.sha256"
sha256: "{{ checksum_stats.stat.checksum }}"
relative_path: "{{ found_files.files[0].path | basename }}.sha256"
state: present
repository: "{{ repository_name }}"
register: checksum_content_result
until: checksum_content_result is success
retries: 3
delay: 5
when: upload_checksum

- name: Ensure file repo exists
pulp.squeezer.file_repository:
pulp_url: "{{ remote_pulp_url }}"
username: "{{ remote_pulp_username }}"
password: "{{ remote_pulp_password }}"
name: "{{ repository_name }}"
state: present
register: file_repo_result
until: file_repo_result is success
retries: 3
delay: 5

- name: Add content to file repo
pulp.squeezer.file_repository_content:
pulp_url: "{{ remote_pulp_url }}"
username: "{{ remote_pulp_username }}"
password: "{{ remote_pulp_password }}"
repository: "{{ repository_name }}"
present_content:
- relative_path: "{{ found_files.files[0].path | basename }}"
sha256: "{{ file_stats.stat.checksum }}"
register: file_repo_content_result
until: file_repo_content_result is success
retries: 3
delay: 5

- name: Add checksum content to file repo
pulp.squeezer.file_repository_content:
pulp_url: "{{ remote_pulp_url }}"
username: "{{ remote_pulp_username }}"
password: "{{ remote_pulp_password }}"
repository: "{{ repository_name }}"
present_content:
- relative_path: "{{ found_files.files[0].path | basename }}.sha256"
sha256: "{{ checksum_stats.stat.checksum }}"
register: checksum_repo_content_result
until: checksum_repo_content_result is success
retries: 3
delay: 5
when: upload_checksum

- name: Create a new publication to point to this version
pulp.squeezer.file_publication:
pulp_url: "{{ remote_pulp_url }}"
Expand Down
4 changes: 3 additions & 1 deletion etc/kayobe/ansible/requirements.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,10 @@
collections:
- name: stackhpc.cephadm
version: 1.19.3
# NOTE: Pinning pulp.squeezer to 0.0.13 because 0.0.14+ depends on the
# pulp_glue Python library being installed.
- name: pulp.squeezer
version: 0.1.1
version: 0.0.13
- name: stackhpc.pulp
version: 0.5.5
- name: stackhpc.hashicorp
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ features:
versions. This includes:

* ``stackhpc.cephadm`` - ``1.19.1`` -> ``1.19.3``
* ``pulp.squeezer`` - ``0.0.13`` -> ``0.1.1``
* ``ansible-lockdown.rhel9_cis`` - ``1.3.1`` -> ``v1.3.4``
* ``geerlingguy.pip`` - ``2.2.0`` -> ``3.1.0``
* ``monolithprojects.github_actions_runner`` - ``1.18.5`` -> ``1.25.1``
Expand Down