diff --git a/ansible-managed/README.md b/ansible-managed/README.md new file mode 100644 index 00000000..5b0f0e9c --- /dev/null +++ b/ansible-managed/README.md @@ -0,0 +1,11 @@ +# ansible-managed + +Set some indications that the server is managed by Ansible and extra care yshould be given not no mess with it manually. + +## Tasks + +Everything is in the `tasks/main.yml` file. + +## Available variables + +* `project_repository` : project URL for the repository. diff --git a/ansible-managed/defaults/main.yml b/ansible-managed/defaults/main.yml new file mode 100644 index 00000000..0fb25789 --- /dev/null +++ b/ansible-managed/defaults/main.yml @@ -0,0 +1,2 @@ +--- +project_repository: "/!\ No repository set, contact Evolix" diff --git a/ansible-managed/tasks/main.yml b/ansible-managed/tasks/main.yml new file mode 100644 index 00000000..7fcbc1fc --- /dev/null +++ b/ansible-managed/tasks/main.yml @@ -0,0 +1,7 @@ +--- +- name: Set message of the day + template: + src: motd.j2 + dest: /etc/motd + force: yes + backup: yes diff --git a/ansible-managed/templates/motd.j2 b/ansible-managed/templates/motd.j2 new file mode 100644 index 00000000..58b468d2 --- /dev/null +++ b/ansible-managed/templates/motd.j2 @@ -0,0 +1,4 @@ + +SERVER MANAGED BY EVOLIX VIA ANSIBLE +------------------------------------ +{{ project_repository | mandatory }}