Skip to content

Commit

Permalink
Add playbook to launch any jenkins job
Browse files Browse the repository at this point in the history
  • Loading branch information
shaior committed May 7, 2024
1 parent 97398d9 commit 3b0c5f4
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 0 deletions.
2 changes: 2 additions & 0 deletions inventory
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[helix37]
10.46.55.161 ansible_ssh_user=kni ansible_ssh_common_args="-o UserKnownHostsFile=/dev/null -o StrictHostKeyChecking=no -o ServerAliveInterval=30" ansible_ssh_private_key_file=~/key
Empty file removed playbooks/.gitkeep
Empty file.
15 changes: 15 additions & 0 deletions playbooks/launch-jenkins-job.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
# This playbook is generic and should be used to launch any jenkins job
# given the job params, url, username and user token.
- name: Launch jenkins job
hosts: all
tasks:
# launch jenkins job using redhatci collection.
- name: Launch jenkins job
ansible.builtin.import_role:
name: redhatci.ocp.jenkins_job_launcher
vars:
jjl_job_params: "{{ job_params }}"
jjl_job_url: "{{ job_url }}"
jjl_username: "{{ username }}"
jjl_token: "{{ token }}"
Empty file removed roles/.gitkeep
Empty file.

0 comments on commit 3b0c5f4

Please sign in to comment.