Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 2234444 - redhat.satellite.content_view_publish role does not include option for adding additional comment and option for automatic promote to environments
Summary: redhat.satellite.content_view_publish role does not include option for adding...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Ansible Collection
Version: 6.13.4
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: 6.14.0
Assignee: satellite6-bugs
QA Contact: Griffin Sullivan
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2023-08-24 12:50 UTC by soham
Modified: 2023-11-08 14:20 UTC (History)
5 users (show)

Fixed In Version: ansible-collection-redhat-satellite-3.14.0
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-11-08 14:20:20 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github theforeman foreman-ansible-modules pull 1597 0 None Merged also accept all parameters of cv_version module 2023-08-29 06:29:15 UTC
Red Hat Issue Tracker SAT-19750 0 None None None 2023-08-29 06:31:41 UTC
Red Hat Product Errata RHSA-2023:6818 0 None None None 2023-11-08 14:20:44 UTC

Description soham 2023-08-24 12:50:01 UTC
Description of problem:
[RFE] redhat.satellite.content_view_publish role does not include option for adding additional comment and option for automatic promote to environments

These request has 2 parts:

1. Add option to add comments while publishing a cv

2. Add automatic promote options while publishing


Both of these options are available on web ui.


Business justification:

Its good to add the description feature available as supported feature of the module it is calling: https://console.redhat.com/ansible/automation-hub/repo/published/redhat/satellite/content/module/content_view_version/

Is this something you can add please? We like to link our publishes with a ticket ID.


Account Name	Synectics Solutions Ltd
Account Number	6171065

Comment 1 soham 2023-08-24 13:00:30 UTC
This seems to be already incorporated in https://github.com/RedHatSatellite/satellite-ansible-collection/blob/develop/roles/content_view_publish/tasks/main.yml#L10-L13


Noticed after opening the RFE.


-Soham

Comment 5 Griffin Sullivan 2023-09-05 16:07:16 UTC
FailedQA on 6.14 snap 14

I hit the following error during my test

TASK [redhat.satellite.content_view_publish : Publish content views] **************************************************************************************************************************
failed: [localhost] (item={'content_view': 'test', 'description': 'daily publish of test view', 'lifecycle_environments': ['testenv'], 'force_promote': True}) => {"ansible_loop_var": "content_view", "changed": false, "content_view": {"content_view": "test", "description": "daily publish of test view", "force_promote": true, "lifecycle_environments": ["testenv"]}, "msg": "The 'version' needs to be in the format 'X.Y', not 'daily publish of test view'"}

Comment 6 Evgeni Golov 2023-09-05 18:16:00 UTC
Griffin's fix was merged.

Comment 7 Patrick Creech 2023-09-06 19:52:05 UTC
https://github.com/RedHatSatellite/satellite-ansible-collection/releases/

Looks like we need a 3.14.0 in github

Comment 8 Evgeni Golov 2023-09-07 06:34:18 UTC
Yepp, that's why I only set "POST", there is no 3.14 release yet :)

(But I'll create one soon)

Comment 9 Evgeni Golov 2023-09-08 14:20:38 UTC
https://gitlab.cee.redhat.com/satellite/satellite-packaging/-/merge_requests/7465 has the changes you wanted!

Comment 10 Griffin Sullivan 2023-09-18 13:46:15 UTC
Verified in 6.14 snap 16

content_view_publish role allows description and promoting to lifecycle environments.

Steps to reproduce:

1) Create an empty lifecycle environment named testenv and empty CV named testview

2) Copy and run this playbook:

---
- hosts: localhost
  roles:
    - role: redhat.satellite.content_view_publish
      vars:
        satellite_server_url: https://satellite-server.url
        satellite_username: "admin"
        satellite_password: "changeme"
        satellite_organization: "Default Organization"
        satellite_content_views:
          - content_view: "testview"
            description: "A test content view"
            force_promote: True
            lifecycle_environments:
              - "testenv"

Result:

PLAY [localhost] ****************************************************************************************************************************************************

TASK [Gathering Facts] **********************************************************************************************************************************************
ok: [localhost]

TASK [redhat.satellite.content_view_publish : Publish content views] ************************************************************************************************
changed: [localhost] => (item={'content_view': 'testview', 'description': 'A test content view', 'force_promote': True, 'lifecycle_environments': ['testenv']})

PLAY RECAP **********************************************************************************************************************************************************
localhost                  : ok=2    changed=1    unreachable=0    failed=0    skipped=0    rescued=0    ignored=0

Comment 13 errata-xmlrpc 2023-11-08 14:20:20 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Important: Satellite 6.14 security and bug fix update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2023:6818


Note You need to log in before you can comment on or make changes to this bug.