From fde556928d8ba7970566d1e445706083a599c9a3 Mon Sep 17 00:00:00 2001 From: binary Date: Fri, 5 Mar 2021 11:33:48 +0100 Subject: Refactor playbook usage --- playbooks/all-hosts-basic.yml | 2 -- playbooks/grafana.yml | 13 ------------- playbooks/network.yml | 6 ++++-- playbooks/network/grafana.yml | 13 +++++++++++++ playbooks/network/localhost.yml | 1 - playbooks/st0gme1.rgoncalves.se.yml | 9 --------- 6 files changed, 17 insertions(+), 27 deletions(-) delete mode 100644 playbooks/grafana.yml create mode 100644 playbooks/network/grafana.yml delete mode 100644 playbooks/st0gme1.rgoncalves.se.yml diff --git a/playbooks/all-hosts-basic.yml b/playbooks/all-hosts-basic.yml index 2aeef8f..5e2662e 100644 --- a/playbooks/all-hosts-basic.yml +++ b/playbooks/all-hosts-basic.yml @@ -7,10 +7,8 @@ - hosts: servers roles: - # basic networking init - { role: repositories } - { role: dns } - # basic user friendly configuration - { role: common } - { role: tools } - { role: sshd } diff --git a/playbooks/grafana.yml b/playbooks/grafana.yml deleted file mode 100644 index 5c3de4e..0000000 --- a/playbooks/grafana.yml +++ /dev/null @@ -1,13 +0,0 @@ - -# network ~~ playbooks/network.yml -# common network configuration - ---- - -- hosts: servers - roles: - - { role: prometheus } - -- hosts: vm1 - roles: - - { role: grafana } diff --git a/playbooks/network.yml b/playbooks/network.yml index 1b34572..14911a6 100644 --- a/playbooks/network.yml +++ b/playbooks/network.yml @@ -19,7 +19,9 @@ roles: - { role: dns } - { role: sshd } - - { role: prometheus } + +- name: import grafana playbook + import_playbook: network/grafana.yml - name: import domain controller playbook - import_playbook: dc0.rgoncalves.se + import_playbook: dc0.rgoncalves.se.yml diff --git a/playbooks/network/grafana.yml b/playbooks/network/grafana.yml new file mode 100644 index 0000000..30bc0f4 --- /dev/null +++ b/playbooks/network/grafana.yml @@ -0,0 +1,13 @@ + +# network ~~ playbooks/network/grafana.yml +# setup grafana for all hosts + +--- + +- hosts: servers + roles: + - { role: prometheus } + +- hosts: st0cld0 + roles: + - { role: grafana } diff --git a/playbooks/network/localhost.yml b/playbooks/network/localhost.yml index 4d87654..32d46fa 100644 --- a/playbooks/network/localhost.yml +++ b/playbooks/network/localhost.yml @@ -9,4 +9,3 @@ roles: - { role: sshdns } - diff --git a/playbooks/st0gme1.rgoncalves.se.yml b/playbooks/st0gme1.rgoncalves.se.yml deleted file mode 100644 index d1be699..0000000 --- a/playbooks/st0gme1.rgoncalves.se.yml +++ /dev/null @@ -1,9 +0,0 @@ - -# st0gme1 ~~ playbooks/st1gme0.rgoncalves.se.yml -# openbsd based game server. - ---- - -- hosts: st0gme1 - roles: - - { role: minecraft , tags: "role_minecraft"} -- cgit v1.2.3