diff --git a/hosts.yml b/hosts.yml index 8162200..9850a3d 100644 --- a/hosts.yml +++ b/hosts.yml @@ -6,4 +6,4 @@ line: '{{ item }}' state: present with_items: - - '{{ ansible_default_ipv4.address }} {{ ansible_hostname }} {{ ansible_hostname }}.gmotech.net' \ No newline at end of file + - '{{ ansible_default_ipv4.address }} {{ ansible_hostname }} {{ ansible_hostname }}.gmetech.net' \ No newline at end of file diff --git a/inst-raps.sh b/inst-raps.sh index fb1444a..c377163 100755 --- a/inst-raps.sh +++ b/inst-raps.sh @@ -147,6 +147,14 @@ printInfo "Update date and time" if [ $? -ne 0 ]; then printError "Problem to update date and time";exit; fi printSuccess "Date and Time updated successfully" +#----------------------------------------------------------------------------- +# update role +#----------------------------------------------------------------------------- +printInfo "Update roles" +~/.local/bin/ansible-galaxy install -f -r roles/requirements.yml +if [ $? -ne 0 ]; then printError "Problem to update roles";exit; fi +printSuccess "Role updated successfully" + #----------------------------------------------------------------------------- # execute playbook #----------------------------------------------------------------------------- diff --git a/main.yml b/main.yml index e706145..9087b24 100644 --- a/main.yml +++ b/main.yml @@ -7,4 +7,8 @@ - include_tasks: hosts.yml - include_tasks: inst-packages.yml - include_tasks: misc.yml + + - name: import netdata role + import_role: + name: role-netdata \ No newline at end of file diff --git a/playbook-chrony.yml b/playbook-chrony.yml index bdcc155..1ff6818 100644 --- a/playbook-chrony.yml +++ b/playbook-chrony.yml @@ -16,10 +16,6 @@ copy: src: chrony/chronyd dest: /etc/sysconfig/chronyd - #replace: - # path: /etc/sysconfig/chronyd - # regexp: '^OPTIONS=""' - # replace: 'OPTIONS="-4"' - name: start and active service chronyd systemd: diff --git a/roles/requirements.yml b/roles/requirements.yml new file mode 100644 index 0000000..30f8952 --- /dev/null +++ b/roles/requirements.yml @@ -0,0 +1,7 @@ +--- +- name: role-netdata + src: git+https://gitweb.dyndns.org/awx/role_netdata.git + +- name: role-apache + src: git+https://gitweb.dyndns.org/awx/role-apache.git +