Bug 1227211

Summary: Foreman - unable to add a tag during provisioning
Product: Red Hat CloudForms Management Engine Reporter: Jan Krocil <jkrocil>
Component: ProvisioningAssignee: Keenan Brock <kbrock>
Status: CLOSED ERRATA QA Contact: Taras Lehinevych <tlehinev>
Severity: medium Docs Contact:
Priority: medium    
Version: 5.4.0CC: dajohnso, jhardy, mfeifer, obarenbo, tlehinev
Target Milestone: GA   
Target Release: 5.5.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: 5.5.0.1 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-12-08 13:15:01 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Jan Krocil 2015-06-02 07:39:02 UTC
Description of problem:
Unable to set tags during provisioning.

Version-Release number of selected component (if applicable):
5.4.0.4

How reproducible:
Always

Steps to Reproduce:
1. Add a foreman provider
2. Provision a configured system with a tag (e.g. cost center)

Actual results:
Provisioning is successful but tag is not applied.

Expected results:
Tag is applied to the configured system during provisioning.

Additional info:

Workaround:
Tags can be applied after provisioning - on the configured system's summary page.

Comment 2 Greg McCullough 2015-06-02 14:29:20 UTC
Keenan - Brandon added the apply_tags call to the post_provision state in app/models/miq_provision_task_configured_system_foreman/state_machine.rb.  This should be easy to test out if the appliance QE was testing with is available.

Comment 6 CFME Bot 2015-06-23 21:34:38 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/517ab3c31237afbcf558089127db70151306d3fa

commit 517ab3c31237afbcf558089127db70151306d3fa
Author:     Keenan Brock <kbrock>
AuthorDate: Mon Jun 22 21:14:55 2015 -0400
Commit:     Keenan Brock <kbrock>
CommitDate: Tue Jun 23 16:37:52 2015 -0400

    move tag_symbol from MiqRequestMethod to workflows
    
    Allow workflow to define how to specify tags.
    Now default to tag_ids (was vm_tags before)
    All children of MiqHostProvisionWorkflow will use vm_tags.
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1227211

 vmdb/app/controllers/application_controller/miq_request_methods.rb | 2 +-
 vmdb/app/models/miq_provision_virt_workflow.rb                     | 4 ++++
 vmdb/app/models/miq_request_workflow.rb                            | 4 ++++
 3 files changed, 9 insertions(+), 1 deletion(-)

Comment 7 CFME Bot 2015-06-23 21:34:42 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/bb4a6544fa1061149e851d94f5eebeb88978595d

commit bb4a6544fa1061149e851d94f5eebeb88978595d
Author:     Keenan Brock <kbrock>
AuthorDate: Mon Jun 22 21:15:56 2015 -0400
Commit:     Keenan Brock <kbrock>
CommitDate: Tue Jun 23 16:37:52 2015 -0400

    Display status message for foreman provision_task
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1227211

 .../models/miq_provision_task_configured_system_foreman/state_machine.rb | 1 +
 1 file changed, 1 insertion(+)

Comment 8 CFME Bot 2015-06-23 21:34:46 UTC
New commit detected on manageiq/master:
https://github.com/ManageIQ/manageiq/commit/aea3ea0605a3f2264f240a6a8b83659a4efd9765

commit aea3ea0605a3f2264f240a6a8b83659a4efd9765
Author:     Keenan Brock <kbrock>
AuthorDate: Mon Jun 22 21:22:05 2015 -0400
Commit:     Keenan Brock <kbrock>
CommitDate: Tue Jun 23 16:37:53 2015 -0400

    foreman provisioning dialog now inputs tag_ids
    
    https://bugzilla.redhat.com/show_bug.cgi?id=1227211

 .../views/miq_request/_prov_configured_system_foreman_dialog.html.haml  | 2 +-
 .../miq_dialogs/miq_provision_configured_system_foreman_dialogs.yaml    | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

Comment 9 Keenan Brock 2015-06-24 15:37:52 UTC
Thanks for all the help Jan

Comment 10 Taras Lehinevych 2015-10-10 15:34:17 UTC
Verified fixed in version 5.5.0.3

The bug doesn't reproduce, after provisioning the tags were assigned.

Comment 12 errata-xmlrpc 2015-12-08 13:15:01 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, 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-2015:2551