added Jenkinsfile
Some checks failed
multibranch_ansible/pipeline/head There was a failure building this commit

This commit is contained in:
2023-06-05 19:31:06 +02:00
parent e82d3d5157
commit 2320b24011
2 changed files with 11 additions and 4 deletions

9
Jenkinsfile vendored
View File

@@ -16,13 +16,20 @@ pipeline {
}
}
stage('Ansible') {
stage('Ansible local run') {
agent any
steps {
ansiblePlaybook playbook: 'local_test.yml'
// ansiblePlaybook credentialsId: '209d0fa2-bbd7-4af5-9aac-deec1b6aa7ec', inventory: '192.168.150.40,', playbook: 'test_play.yml'
}
}
stage('Ansible Remote') {
agent any
steps {
ansiblePlaybook credentialsId: '209d0fa2-bbd7-4af5-9aac-deec1b6aa7ec', inventory: '192.168.50.40,', playbook: 'test_play.yml'
}
}
}
}

View File

@@ -3,9 +3,9 @@
- name: "TestPlay"
gather_facts: true
become: false
#hosts: 192.168.150.40
hosts: localhost
connection: local
hosts: 192.168.50.40
#hosts: localhost
#connection: local
tasks:
- debug:
msg: "Hello World"