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

Execute playbook with the incoming clusters data #9

Merged
merged 4 commits into from
Mar 25, 2022

Conversation

arbulu89
Copy link
Contributor

Execute the actual ansible playbook.

For that, the execution inventories are created based on the ExecutionEvent coming from the /api/execute call.

The python callbacks code has not been changed yet. This will come in a subsequent PR. By now, the callbacks just sends the old structure.

This is an example of a request:

{
   execution_id: "779cdd70-e9e2-58ca-b18a-bf3eb3f71244",
   clusters: [
      {
         cluster_id: "779cdd70-e9e2-58ca-b18a-bf3eb3f71244",
         provider: "azure",
         checks: [
            "156F64",
            "53D035",
            "A1244C"
         ],
         hosts: [
            {
               host_id: "779cdd70-e9e2-58ca-b18a-bf3eb3f71241",
               address: "10.162.29.43",
               user: "root"
            },
            {
               host_id: "779cdd70-e9e2-58ca-b18a-bf3eb3f71240",
               address: "10.162.30.229",
               user: "root"
            }
         ]
      },
      {
         cluster_id: "779cdd70-e9e2-58ca-b18a-bf3eb3f71245",
         provider: "azure",
         checks: [
            "845CC9",
            "24ABCB"
         ],
         hosts: [
            {
               host_id: "779cdd70-e9e2-58ca-b18a-bf3eb3f71243",
               address: "10.162.29.43",
               user: "root"
            },
            {
               host_id: "779cdd70-e9e2-58ca-b18a-bf3eb3f71246",
               address: "10.162.30.226",
               user: "root"
            }
         ]
      }
   ]
}

Copy link
Member

@nelsonkopliku nelsonkopliku left a comment

Choose a reason for hiding this comment

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

LGTM

@arbulu89 arbulu89 merged commit 964f075 into trento-project:main Mar 25, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Development

Successfully merging this pull request may close these issues.

2 participants