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

fix: build the JOB URL on the server side #948

Merged
merged 2 commits into from
Jun 21, 2024
Merged

Conversation

mkanoor
Copy link
Contributor

@mkanoor mkanoor commented Jun 21, 2024

With the advent of controller behind our server the URL to access the job details for JobTemplate and WorkflowTemplate has changed

We have an api end point that is specificed in the RH AAP Credential Type this is sent to the ansible-rulebook so that it can talk to the controller via the api. This end point could point to a controller directly or to a controller behind our server.

To directly access the controller we only need the host and port so the API end point would look like
e.g. https://<<your_controller>>/

This will map the Job URL for a Job Template to look like
https://<<your_controller>>/#/jobs/playbook/23/details/
This will map the Job URL for a Workflow Template to look like
https://<<your_controller>>/#/jobs/workflow/24/details/

When the controller is behind our server the API end point is e.g. https://<<your_server>>/api/controller

This will map the Job URL for a Job Template to look like
https://<<your_server>>/execution/jobs/playbook/25/details/
This will map the Job URL for a Workflow Template to look like
https://<<your_server>>/execution/jobs/workflow/26/details/

For this to work correctly we need ansible-rulebook to pass in the controller_job_id and the action_type. Currently it doesn't send up the controller_job_id which is being fixed in a separate PR.

https://issues.redhat.com/browse/AAP-25604

@mkanoor mkanoor requested a review from a team as a code owner June 21, 2024 14:34
With the advent of controller behind our server the URL to
access the job details for JobTemplate and WorkflowTemplate has changed

We have an api end point that is specificed in the RH AAP Credential
Type this is sent to the ansible-rulebook so that it can talk to
the controller via the api. This end point could point to a controller
directly or to a controller behind our server.

To directly access the controller we only need the host and port so the
API end point would look like
e.g. https://<<your_controller>>/

This will map the Job URL for a Job Template to look like
     https://<<your_controller>>/#/jobs/playbook/23/details/
This will map the Job URL for a Workflow Template to look like
     https://<<your_controller>>/#/jobs/workflow/24/details/

When the controller is behind our server the API end point is
e.g. https://<<your_server>>/api/controller

This will map the Job URL for a Job Template to look like
     https://<<your_server>>/execution/jobs/playbook/25/details/
This will map the Job URL for a Workflow Template to look like
     https://<<your_server>>/execution/jobs/workflow/26/details/

For this to work correctly we need ansible-rulebook to pass in
the controller_job_id and the action_type. Currently it doesn't
send up the controller_job_id which is being fixed in a separate
PR.

https://issues.redhat.com/browse/AAP-25604
@mkanoor mkanoor merged commit 0d10ac7 into ansible:main Jun 21, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants