Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes #36808 - Add sudo to Resolve Traces template #10762

Merged
merged 1 commit into from
Oct 12, 2023

Conversation

jeremylenz
Copy link
Member

@jeremylenz jeremylenz commented Oct 6, 2023

What are the changes introduced in this pull request?

In the Resolve Traces - Katello Script Default template, use sudo when running katello-tracer-upload. This will allow REX to use a non-root user when executing the job.

Considerations taken when implementing this change?

We also have a "Resolve Traces - Katello Ansible Default" but I didn't change that one because I think Ansible defaults to become: true anyway, is that right?

What are the testing steps for this pull request?

Check out the PR.
Refresh your job templates:

# bundle exec rails console
ForemanInternal.all.last.destroy

Then go look at the locked job template and verify that it's updated. Bonus: actually run it via REX as a non-root user

@theforeman-bot
Copy link

Issues: #36808

@jeremylenz
Copy link
Member Author

[test katello]

1 similar comment
@jeremylenz
Copy link
Member Author

[test katello]

@chris1984
Copy link
Member

Code wise it looks fine and your comment about become: true is correct so we are becoming sudo anyways. Starting to test

Copy link
Member

@chris1984 chris1984 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK works great.

Screenshot showing locked template is updated:
prtemplate

Screenshot showing vagrant user being used instead of root:
Screenshot 2023-10-10 at 14-26-59 Run job

Screenshot showing job completed:
Screenshot 2023-10-10 at 14-28-26 Resolve Traces

@ianballou
Copy link
Member

[test katello]

@chris1984
Copy link
Member

@jeremylenz All green :)

@chris1984 chris1984 self-assigned this Oct 12, 2023
@jeremylenz jeremylenz merged commit f310056 into Katello:master Oct 12, 2023
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants