Project

Profile

Help

Issue #2080

closed

All steps in "lazy" role are skipped for Pulp 2.10

Added by Ichimonji10 almost 8 years ago. Updated over 3 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
Normal
Assignee:
-
Start date:
Due date:
Estimated time:
Severity:
2. Medium
Version - Packaging:
Platform Release:
Target Release - Packaging:
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Quarter:

Description

Consider a scenario where one provisions a Fedora 23 system, and then executes this script:

#!/usr/bin/env sh
set -euo pipefail

dnf update -y
dnf install -y git vim ansible python-dnf libselinux-python
mkdir code && cd code
git clone https://github.com/pulp/pulp_packaging && cd pulp_packaging
echo localhost > hosts
ansible-playbook -i hosts --connection local -e pulp_version='2.10' \
    ci/ansible/pulp_server.yaml

For some reason, the steps in the "lazy" role are skipped. Ansible dumps this information to stdout:

TASK [lazy : Install lazy packages] ********************************************
skipping: [localhost] => (item=[])

TASK [lazy : Install squid proxy configuration] ********************************
skipping: [localhost]

TASK [lazy : Install squid-3.1 proxy configuration] ****************************
skipping: [localhost]

TASK [lazy : file] *************************************************************
skipping: [localhost]

TASK [lazy : Start and enable Squid service] ***********************************
skipping: [localhost]

TASK [lazy : Start and enable Pulp streamer service] ***************************
skipping: [localhost]

When pulp_version='2.9' or earlier, the steps in the "lazy" role execute. Ansible dumps this information to stdout:

TASK [lazy : Install lazy packages] ********************************************
changed: [localhost] => (item=[u'squid', u'httpd', u'python-pulp-streamer'])

TASK [lazy : Install squid proxy configuration] ********************************
changed: [localhost]

TASK [lazy : Install squid-3.1 proxy configuration] ****************************
skipping: [localhost]

TASK [lazy : file] *************************************************************
ok: [localhost]

TASK [lazy : Start and enable Squid service] ***********************************
changed: [localhost]

TASK [lazy : Start and enable Pulp streamer service] ***************************
changed: [localhost]

Here's the list of packages that are installed when installing Pulp 2.10:

# rpm -qa | grep -i pulp | sort
pulp-admin-client-2.10.0-0.1.alpha.git.389.6effdbb.fc23.noarch
pulp-docker-admin-extensions-2.1.0-0.1.alpha.git.111.44298c3.fc23.noarch
pulp-docker-plugins-2.1.0-0.1.alpha.git.111.44298c3.fc23.noarch
pulp-ostree-admin-extensions-1.2.0-0.1.alpha.git.77.7dbe335.fc23.noarch
pulp-ostree-plugins-1.2.0-0.1.alpha.git.77.7dbe335.fc23.noarch
pulp-puppet-admin-extensions-2.10.0-0.1.alpha.git.132.e3ed18b.fc23.noarch
pulp-puppet-plugins-2.10.0-0.1.alpha.git.132.e3ed18b.fc23.noarch
pulp-python-admin-extensions-1.2.0-0.1.alpha.git.80.88f1b08.fc23.noarch
pulp-python-plugins-1.2.0-0.1.alpha.git.80.88f1b08.fc23.noarch
pulp-rpm-admin-extensions-2.10.0-0.1.alpha.git.337.69e065e.fc23.noarch
pulp-rpm-plugins-2.10.0-0.1.alpha.git.337.69e065e.fc23.noarch
pulp-selinux-2.10.0-0.1.alpha.git.389.6effdbb.fc23.noarch
pulp-server-2.10.0-0.1.alpha.git.389.6effdbb.fc23.noarch
python-kombu-3.0.33-5.pulp.fc23.noarch
python-pulp-bindings-2.10.0-0.1.alpha.git.389.6effdbb.fc23.noarch
python-pulp-client-lib-2.10.0-0.1.alpha.git.389.6effdbb.fc23.noarch
python-pulp-common-2.10.0-0.1.alpha.git.389.6effdbb.fc23.noarch
python-pulp-docker-common-2.1.0-0.1.alpha.git.111.44298c3.fc23.noarch
python-pulp-oid_validation-2.10.0-0.1.alpha.git.389.6effdbb.fc23.noarch
python-pulp-ostree-common-1.2.0-0.1.alpha.git.77.7dbe335.fc23.noarch
python-pulp-puppet-common-2.10.0-0.1.alpha.git.132.e3ed18b.fc23.noarch
python-pulp-python-common-1.2.0-0.1.alpha.git.80.88f1b08.fc23.noarch
python-pulp-repoauth-2.10.0-0.1.alpha.git.389.6effdbb.fc23.noarch
python-pulp-rpm-common-2.10.0-0.1.alpha.git.337.69e065e.fc23.noarch

Notice that python-pulp-streamer is not present.

I've tried fixing this by editing the pulp_packaging repository like so:

diff --git a/ci/ansible/pulp_server.yaml b/ci/ansible/pulp_server.yaml
index 8a5294f..5bcaf02 100644
--- a/ci/ansible/pulp_server.yaml
+++ b/ci/ansible/pulp_server.yaml
@@ -5,6 +5,5 @@
     - role: pulp
       pulp_install_server: true
     - role: lazy
-      when: pulp_version|float >= 2.8
     - role: pulp-certs
   sudo: true

But this has no apparent effect.

Actions #1

Updated by Ichimonji10 almost 8 years ago

I've tried fixing this by editing the pulp_packaging repository like so:

[...]

But this has no apparent effect.

I goofed up here. Applying the diff does work, as does applying this diff:

diff --git a/ci/ansible/pulp_server.yaml b/ci/ansible/pulp_server.yaml
index 8a5294f..c9b6fac 100644
--- a/ci/ansible/pulp_server.yaml
+++ b/ci/ansible/pulp_server.yaml
@@ -5,6 +5,6 @@
     - role: pulp
       pulp_install_server: true
     - role: lazy
-      when: pulp_version|float >= 2.8
+      when: pulp_version | version_compare('2.8', '>=')
     - role: pulp-certs
   sudo: true

I'll submit a PR.

Actions #2

Updated by Ichimonji10 almost 8 years ago

  • Status changed from NEW to MODIFIED
Actions #3

Updated by Ichimonji10 almost 8 years ago

  • Status changed from MODIFIED to 6
Actions #4

Updated by amacdona@redhat.com almost 8 years ago

  • Triaged changed from No to Yes
Actions #5

Updated by bmbouter about 5 years ago

  • Tags Pulp 2 added
Actions #6

Updated by bmbouter over 3 years ago

  • Status changed from 6 to CLOSED - CURRENTRELEASE

Also available in: Atom PDF