In this article, we learn how to create a webhook in GitLab Repo to integrate it with Ansible Automation Platform.
Below are the steps involved
Create
Gitlab Access Token:
You have to go to your GitLab project. You need to go to Settings → Access Token. Based on your requirement you need to select options and create an access token. once created you will see a token display on the GitLab page. Please save the token because you cannot edit the token. You can only delete tokens.
Create a new credential in AAP:
Next, we will use this token to create a new credential in Ansible Tower of type “GitLab Personal Access Token”. Please paste the saved token in the token field.
Upon saving, the Ansible controller now has API access to my GitLab account.
JobTemplate:
When you are running a job template you need to check the webhook check in the job
Try Push coding using git push and Now you will see an ansible automation controller running the job.
Tags: AI,MLops
Ansible Automation Platform