Project

General

Profile

Bug #24207

user with minimal rights to play Ansible on host is unable to do so: PG::NotNullViolation: ERROR: null value in column "targeting_id" violates not-null constraint

Added by Marek Hulán over 3 years ago. Updated over 3 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Target version:
Difficulty:
Triaged:
No
Bugzilla link:

Description

Cloned from https://bugzilla.redhat.com/show_bug.cgi?id=1574533

Description of problem:
User with minimal rights to play Ansible on host is unable to do so:

Oops, we're sorry but something went wrong PG::NotNullViolation: ERROR: null value in column "targeting_id" violates not-null constraint DETAIL: Failing row contains (12, null, null, null, null, null, null, null, null, null, null, null, null). : INSERT INTO "job_invocations" DEFAULT VALUES RETURNING "id"

Version-Release number of selected component (if applicable):
satellite-6.4.0-3.beta.el7sat.noarch
rubygem-smart_proxy_ansible-2.0.2-3.el7sat.noarch
tfm-rubygem-foreman_ansible_core-2.0.2-1.el7sat.noarch
tfm-rubygem-foreman_ansible-2.0.4-1.el7sat.noarch
ansible-2.4.2.0-2.el7.noarch

How reproducible:
always

Steps to Reproduce:
1. Have Sat with some roles imported and host with role assigned
(I have used linuxhq.setup)
2. Create user (in correct org and loc - also I have configured default
"after login" org and loc)
3. Grant that user access roles "Ansible Roles Manager" and "Viewer"
4. Login as that user and make sure you can see your host in Hosts -> All hosts
5. Hosts -> All hosts -> <host> -> Run Ansible roles

Actual results:
ISE

Expected results:
Should work

Associated revisions

Revision 13c13d39 (diff)
Added by Marek Hulán over 3 years ago

Fixes #24207 - don't display run buttons for unauthorized users

History

#1 Updated by The Foreman Bot over 3 years ago

  • Assignee set to Marek Hulán
  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman_ansible/pull/185 added

#2 Updated by Marek Hulán over 3 years ago

  • % Done changed from 0 to 100
  • Status changed from Ready For Testing to Closed

#3 Updated by Marek Hulán over 3 years ago

  • Target version set to foreman-ansible 2.2.2
  • Subject changed from user with minimal rights to play Ansible on host is unable to do so: PG::NotNullViolation: ERROR: null value in column "targeting_id" violates not-null constraint to user with minimal rights to play Ansible on host is unable to do so: PG::NotNullViolation: ERROR: null value in column "targeting_id" violates not-null constraint

#4 Updated by Marek Hulán over 3 years ago

  • Fixed in Releases foreman-ansible 2.2.2 added

Also available in: Atom PDF