Skip to content

Commit

Permalink
ansible: improve the sample project (more role) (#260)
Browse files Browse the repository at this point in the history
  • Loading branch information
tungbq authored Sep 14, 2023
2 parents c9b5623 + c91da4e commit e54d6a2
Show file tree
Hide file tree
Showing 7 changed files with 11 additions and 3 deletions.
7 changes: 5 additions & 2 deletions topics/ansible/projects/sample_project/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,12 @@
- name: Main Playbook
hosts: my-localhost
tasks:
- name: Include ping-google
- name: Include sample_role
import_role:
name: ping-google
name: sample_role
- name: Include ping_google
import_role:
name: ping_google
- name: Include check_up_time
import_role:
name: check_up_time
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
---
google_server: "google.com"
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
---
- name: Ping google.com
ping:
data: "google.com"
data: "{{ google_server }}"
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
- name: Greetings!
ansible.builtin.command: echo "Hello from sample_role"

0 comments on commit e54d6a2

Please sign in to comment.