Pulp: Issueshttps://pulp.plan.io/https://pulp.plan.io/favicon.ico2021-10-27T18:51:23ZPulp
Planio Ansible Plugin - Issue #9546 (CLOSED - DUPLICATE): When syncing a collection version, all its sig...https://pulp.plan.io/issues/95462021-10-27T18:51:23Zrochacbruno
<p><strong>Ticket moved to GitHub</strong>: "pulp/pulp_ansible/748":<a href="https://github.com/pulp/pulp_ansible/issues/748" class="external">https://github.com/pulp/pulp_ansible/issues/748</a></p>
<hr>
<p>Related to <a href="https://pulp.plan.io/issues/9543" class="external">https://pulp.plan.io/issues/9543</a></p>
<p>Story:</p>
<ul>
<li>All collections are signed on the host system</li>
<li>When syncing to another instance, together with all the artifacts/versions, signatures will also need to be synced</li>
<li>If for example a signature is corrupted on the source system, user may redo the signature, invalidate the current, do signature rotation and then the clients will need to re-sync to fetch new valid signatures</li>
</ul> Ansible Plugin - Issue #9534 (CLOSED - DUPLICATE): Ansible Galaxy Repo failed to synchronize case...https://pulp.plan.io/issues/95342021-10-25T15:15:01Zstosem
<p><strong>Ticket moved to GitHub</strong>: "pulp/pulp_ansible/747":<a href="https://github.com/pulp/pulp_ansible/issues/747" class="external">https://github.com/pulp/pulp_ansible/issues/747</a></p>
<hr>
<p>The galaxy.ansible.com API uses case-insensitive fields for the owner username and role name. The Ansible Galaxy Hub source code: <a href="https://github.com/ansible/galaxy/blob/e0e4b909171ddc6ca40f0ef2f7d4dce5680777ce/galaxy/api/views/roles.py#L50" class="external">https://github.com/ansible/galaxy/blob/e0e4b909171ddc6ca40f0ef2f7d4dce5680777ce/galaxy/api/views/roles.py#L50</a></p>
<p>But pulp usesnamespace=namespace. It causes the error on case-sensitive repositories (404 not found, or empty set). An example:</p>
<ul>
<li><a href="https://galaxy.ansible.com/api/v1/roles/?owner__username=Oefenweb" class="external">https://galaxy.ansible.com/api/v1/roles/?owner__username=Oefenweb</a></li>
<li><a href="https://galaxy.ansible.com/api/v1/roles/?owner__username=oefenweb" class="external">https://galaxy.ansible.com/api/v1/roles/?owner__username=oefenweb</a></li>
</ul>
<p>Galaxy Ansible returns the same result. But pulp isn't.</p>
<p>So we can't install roles like this using regular <code>ansible-galaxy install oefenweb.postfix</code> command with the Pulp repo.</p> Ansible Plugin - Issue #9220 (CLOSED - CURRENTRELEASE): content_ansible_collection_versions_creat...https://pulp.plan.io/issues/92202021-08-09T17:07:09Zsajha
<p>The <a href="https://docs.pulpproject.org/pulp_ansible/restapi.html#operation/upload_collection" class="external">https://docs.pulpproject.org/pulp_ansible/restapi.html#operation/upload_collection</a> endpoint allows you to upload a Collection tarball. This operation results in an artifact which can then be used to create a new collection content.</p>
<p>However, the endpoint to do so <a href="https://docs.pulpproject.org/pulp_ansible/restapi.html#operation/content_ansible_collection_versions_create" class="external">https://docs.pulpproject.org/pulp_ansible/restapi.html#operation/content_ansible_collection_versions_create</a> seems to have a lot of required fields which are presumably avaialble on the uploaded tarball itself. Is there a way to modify the flow so that associating an artifact from an uploaded collection tarball doesn't need to have all the other information passed.</p>
<p>I am assuming the flow would be to upload tarball, create a collection content using the artifact, add content created to a collection repository.</p> Ansible Plugin - Issue #8957 (CLOSED - CURRENTRELEASE): URL validation error on remote displays r...https://pulp.plan.io/issues/89572021-06-23T18:27:37Zsajha
<p>The url validation is somehow leading to this: ["Invalid URL https://galaxy.ansible.com/. Ensure the URL ends '/'."]} This happens when I have some source specified in the requirements.yml without the trailing "/".. However the error displays the remote URL in the error which happens to have the trailing /..</p>
<p>(02:14:32 PM) rochacbruno: error is on <a href="https://github.com/pulp/pulp_ansible/blob/master/pulp_ansible/app/serializers.py#L166" class="external">https://github.com/pulp/pulp_ansible/blob/master/pulp_ansible/app/serializers.py#L166</a>
(02:14:44 PM) rochacbruno: should be url=url instead of data["url"]</p> Ansible Plugin - Issue #8923 (CLOSED - CURRENTRELEASE): Backport streamed collection endpoints to...https://pulp.plan.io/issues/89232021-06-18T18:26:07Zrochacbruno
<p>Backport the PRS</p>
<p><a href="https://github.com/pulp/pulp_ansible/pull/573" class="external">https://github.com/pulp/pulp_ansible/pull/573</a></p>
<p><a href="https://github.com/pulp/pulp_ansible/pull/562" class="external">https://github.com/pulp/pulp_ansible/pull/562</a></p>
<p>So galaxy_ng can use the optimized sync</p> Ansible Plugin - Issue #8742 (CLOSED - DUPLICATE): Ansible playbooks fail on database migrationshttps://pulp.plan.io/issues/87422021-05-13T07:09:03Zsli720
<p>I run the ansible playbooks from pulp-installer 3.12.2 (also once with the latest commit of the master branch) on a fresh CentOS 8 as I did last week but suddenly it breaks on database migration with the error:</p>
<pre><code class="text syntaxhl" data-language="text">File \"/usr/local/lib/pulp/lib64/python3.6/site-packages/click/core.py\", line 2108, in __init__", " ) from None", "ValueError: 'default' must be a list when 'multiple' is true."], "stdout": "", "stdout_lines": []}
</code></pre>
<p>Is the click package incompatible? I really don't know now which version of the pulp-installer really works, cause on every rerun of the playbooks another issue appears mostly due to 3rd party incompatibilities (also django upgrade recently broke the installation) . Would it somehow possible to fix all this dependencies somewhere (which file?) cause when I check out 3.12.2 I always expect the same result? Or is there something I do wrong?</p> Ansible Plugin - Issue #8290 (CLOSED - CURRENTRELEASE): Pulp_ansible unable to sync from galaxy e...https://pulp.plan.io/issues/82902021-02-22T18:00:20Zsajha
<p>Steps to reproduce:
Set up a remote with a token and point to a galaxy instance.</p>
<pre><code> {
"auth_url": null,
"ca_cert": null,
"client_cert": null,
"client_key": null,
"download_concurrency": 10,
"name": "hub_1-128797",
"password": null,
"policy": "immediate",
"proxy_url": null,
"pulp_created": "2021-02-19T19:05:47.231796Z",
"pulp_href": "/pulp/api/v3/remotes/ansible/collection/91c20a7d-8477-48d8-86df-46755cdffcae/",
"pulp_last_updated": "2021-02-22T16:53:00.377091Z",
"requirements_file": "---\ncollections:\n- ibm.cloudcollection",
"tls_validation": false,
"token": "xxx-valid-token-xxx",
"url": "https://hostname/api/galaxy/content/community/",
"username": null
},
</code></pre>
<p>When syncing this, I get a 403 from the endpoint with the following logs:</p>
<pre><code>Feb 22 17:13:53 hub-sat1-v4-2-1-jhardy gunicorn[74032]: pulp: django.request:WARNING: Forbidden: /api/galaxy/content/community/
Feb 22 17:13:53 hub-sat1-v4-2-1-jhardy gunicorn[74032]: pulp [-]: - - [22/Feb/2021:17:13:53 +0000] "GET /api/galaxy/content/community/ HTTP/1.0" 403 112 "-" "pulpcore/3.7.3 (cpython 3.6.8-final0, Linux x86_64) (aiohttp 3.7.2)"
Feb 22 17:13:54 hub-sat1-v4-2-1-jhardy gunicorn[74032]: pulp: django.request:WARNING: Forbidden: /api/galaxy/content/community/api/
Feb 22 17:13:54 hub-sat1-v4-2-1-jhardy gunicorn[74032]: pulp [-]: - - [22/Feb/2021:17:13:54 +0000] "GET /api/galaxy/content/community/api/ HTTP/1.0" 403 112 "-" "pulpcore/3.7.3 (cpython 3.6.8-final0, Linux x86_64) (aiohttp 3.7.2)"
</code></pre>
<p>PS: "tls_validation": false is set on the remote.</p>
<p>A ansible-galaxy client with the below cfg file:</p>
<p>[galaxy]
server_list = community_repo</p>
<p>[galaxy_server.community_repo]
url=<a href="https://hostname/api/galaxy/content/community/" class="external">https://hostname/api/galaxy/content/community/</a>
token=xxx-valid-token-xxx</p>
<p>gives the following results:</p>
<p>Secure:</p>
<pre><code># ansible-galaxy collection install -p ./ ibm.cloudcollection
Process install dependency map
ERROR! Unknown error when attempting to call Galaxy at 'https://hub-sat1-v4-2-1-jhardy.c.ansible-tower-engineering.internal/api/galaxy/content/community/api': <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:618)>
</code></pre>
<p>Ignore SSL certificate validation errors with -c :</p>
<pre><code># ansible-galaxy collection install -c -p ./ ibm.cloudcollection
Process install dependency map
Starting collection install process
Installing 'ibm.cloudcollection:1.21.0' to '/root/ansible_collections/ibm/cloudcollection'
</code></pre>
<p>Expected result:
Pulp_Ansible should be able to ignore cert validations and sync successfully when tls_validation is off.</p> Ansible Plugin - Issue #8051 (CLOSED - CURRENTRELEASE): Token refresh POST request is missing pro...https://pulp.plan.io/issues/80512021-01-08T00:28:18Zrochacbruno
<p>On this line</p>
<p><a href="https://github.com/pulp/pulp_ansible/blob/97e705403fb981113a79ee4c5bd592f50ef3283f/pulp_ansible/app/downloaders.py#L160" class="external">https://github.com/pulp/pulp_ansible/blob/97e705403fb981113a79ee4c5bd592f50ef3283f/pulp_ansible/app/downloaders.py#L160</a></p>
<pre><code class="python syntaxhl" data-language="python"><span class="k">async</span> <span class="k">with</span> <span class="bp">self</span><span class="p">.</span><span class="n">session</span><span class="p">.</span><span class="n">post</span><span class="p">(</span><span class="n">url</span><span class="p">,</span> <span class="n">data</span><span class="o">=</span><span class="n">form_payload</span><span class="p">,</span> <span class="n">raise_for_status</span><span class="o">=</span><span class="bp">True</span><span class="p">)</span> <span class="k">as</span> <span class="n">response</span><span class="p">:</span>
</code></pre>
<p>A POSt request is made to refresh token but the request is missing the proxy argument when it is provided on remote.</p>
<p>All requests must use the proxy like this <a href="https://github.com/pulp/pulp_ansible/blob/97e705403fb981113a79ee4c5bd592f50ef3283f/pulp_ansible/app/downloaders.py#L132" class="external">https://github.com/pulp/pulp_ansible/blob/97e705403fb981113a79ee4c5bd592f50ef3283f/pulp_ansible/app/downloaders.py#L132</a></p>
<pre><code class="python syntaxhl" data-language="python"><span class="k">async</span> <span class="k">with</span> <span class="bp">self</span><span class="p">.</span><span class="n">session</span><span class="p">.</span><span class="n">get</span><span class="p">(</span><span class="bp">self</span><span class="p">.</span><span class="n">url</span><span class="p">,</span> <span class="n">headers</span><span class="o">=</span><span class="n">headers</span><span class="p">,</span> <span class="n">proxy</span><span class="o">=</span><span class="bp">self</span><span class="p">.</span><span class="n">proxy</span><span class="p">)</span> <span class="k">as</span> <span class="n">response</span><span class="p">:</span>
</code></pre>
<p>Galaxy Related Bugzilla <a href="https://bugzilla.redhat.com/show_bug.cgi?id=1913816" class="external">https://bugzilla.redhat.com/show_bug.cgi?id=1913816</a></p>
<p>and <a href="https://issues.redhat.com/browse/AAH-248" class="external">https://issues.redhat.com/browse/AAH-248</a></p> Ansible Plugin - Issue #8039 (CLOSED - CURRENTRELEASE): Duplicate error on sync when collection a...https://pulp.plan.io/issues/80392021-01-05T17:13:37Zrochacbruno
<p>Reported as Galaxy issue 179 <a href="https://issues.redhat.com/browse/AAH-179" class="external">https://issues.redhat.com/browse/AAH-179</a></p>
<p>duplicate key value violates unique constraint "unique_is_highest" DETAIL: Key (collection_id, is_highest)=(29f416e2-27e6-46ad-9b10-f520dd5d5dfd, t) already exists.</p> Ansible Plugin - Issue #5711 (CLOSED - CURRENTRELEASE): Unnecessary DELETE action for set_certifi...https://pulp.plan.io/issues/57112019-11-14T11:36:24Zromanblanco
<p>The <code>DELETE</code> action has become unused after merging <a href="https://github.com/ansible/galaxy-api/pull/111/files#diff-54ac93fd48d6c179a17e04d0a104efedL146" class="external">https://github.com/ansible/galaxy-api/pull/111</a>,<br>
making it unnecessary to keep in pulp_ansible repository.</p>
<p>Removing the action is done in Pull Request <a href="https://github.com/pulp/pulp_ansible/pull/247" class="external">https://github.com/pulp/pulp_ansible/pull/247</a>.</p> Ansible Plugin - Issue #5167 (CLOSED - CURRENTRELEASE): Collection Remote sync does not accept mi...https://pulp.plan.io/issues/51672019-07-22T17:33:18Zsajha
<p>The sync operation with a collection remote doesn't honor mirror parameter. Sync succeeds but the contents not present upstream are not removed from the repo version.</p>
<pre><code>Calling API: RemotesCollectionApi.sync ...
HTTP request body param ~BEGIN~
{"repository":"/pulp/api/v3/repositories/88e8ca8c-2da6-4407-81b1-832df39d277c/","mirror":true}
~END~
</code></pre> Ansible Plugin - Issue #5001 (CLOSED - CURRENTRELEASE): Provide content_ansible_collection_read m...https://pulp.plan.io/issues/50012019-06-20T18:37:10Zsajha
<p>We need the ability to read ansible collection content similar to other content types ex: <a href="https://pulp-ansible.readthedocs.io/en/latest/restapi.html#operation/content_ansible_roles_read" class="external">https://pulp-ansible.readthedocs.io/en/latest/restapi.html#operation/content_ansible_roles_read</a>.</p> Ansible Plugin - Issue #4997 (CLOSED - CURRENTRELEASE): Pulp3 Ansible Collection remote doesn't s...https://pulp.plan.io/issues/49972019-06-20T16:19:01Zsajha
<p>*Steps to Reproduce:*++<br>
Steps based on httpie and jq from documentation: <a href="https://pulp-ansible.readthedocs.io/en/latest/workflows/index.html" class="external">https://pulp-ansible.readthedocs.io/en/latest/workflows/index.html</a></p>
<p>#Create 2 separate repos:<br>
http POST $BASE_ADDR/pulp/api/v3/repositories/ name=test1<br>
http POST $BASE_ADDR/pulp/api/v3/repositories/ name=test2</p>
<p>export REPO_HREF1=$(http $BASE_ADDR/pulp/api/v3/repositories/ | \<br>
jq -r '.results[] | select(.name == "test1") | ._href')</p>
<p>export REPO_HREF2=$(http $BASE_ADDR/pulp/api/v3/repositories/ | \<br>
jq -r '.results[] | select(.name == "test2") | ._href')</p>
<p>#Create collection remote:</p>
<p>http POST $BASE_ADDR/pulp/api/v3/remotes/ansible/collection/ \<br>
name='bar' \<br>
url='<a href="https://galaxy-dev.ansible.com" class="external">https://galaxy-dev.ansible.com</a>' \<br>
whitelist='newswangerd.collection_demo'</p>
<p>export REMOTE_HREF=$(http $BASE_ADDR/pulp/api/v3/remotes/ansible/collection/ | jq -r '.results[] | select(.name == "bar") | ._href')</p>
<p>#Sync both repos with the remote</p>
<p>export TASK_URL1=$(http POST $BASE_ADDR$REMOTE_HREF'sync/' repository=$REPO_HREF1 \<br>
| jq -r '.task')</p>
<p>export TASK_URL2=$(http POST $BASE_ADDR$REMOTE_HREF'sync/' repository=$REPO_HREF2 \<br>
| jq -r '.task')</p>
<p>#Notice that a new repo version is created by 1st task but none by the 2nd.</p>
<p>http $BASE_ADDR$TASK_URL1</p>
<p>http $BASE_ADDR$TASK_URL2</p>
<p>*<strong>*</strong>*********************************************************</p>
<p>I tried with a second remote pointing to the same URL and with the same whitelist and it doesn't seem to create a repo version either.</p> Ansible Plugin - Issue #4996 (CLOSED - CURRENTRELEASE): Ansible collection remote doesn't handle ...https://pulp.plan.io/issues/49962019-06-19T20:06:58Zsajha
<p>Ex:<br>
With a url <a href="https://galaxy.ansible.com" class="external">https://galaxy.ansible.com</a> it works fine.<br>
With a url <a href="https://galaxy.ansible.com/" class="external">https://galaxy.ansible.com/</a> , throws the following error: <a href="https://gist.github.com/sjha4/0afdd783bac7cea56055b706f6b02155" class="external">https://gist.github.com/sjha4/0afdd783bac7cea56055b706f6b02155</a></p> Ansible Plugin - Issue #3898 (CLOSED - CURRENTRELEASE): Filters inherit from a Django's FilterSet...https://pulp.plan.io/issues/38982018-08-02T15:13:08Zvdusek
<p>AnsibleRoleFilter and AnsibleRoleVersionFilter inherit from Django's filterset.FilterSet class not from our BaseFilterSet. I suppose this could cause problems in generating documentation.</p>