diff --git a/roles/ldap-client/tasks/main.yml b/roles/ldap-client/tasks/main.yml index 3912f981..8195e6f1 100644 --- a/roles/ldap-client/tasks/main.yml +++ b/roles/ldap-client/tasks/main.yml @@ -36,7 +36,7 @@ # Disable passwd and chsh - name: Copy passwd and chsh scripts template: - src: bin/passwd.j2 + src: "bin/{{ item }}.j2" dest: "/usr/local/bin/{{ item }}" mode: 0755 loop: diff --git a/roles/ldap-client/templates/bin/chsh.j2 b/roles/ldap-client/templates/bin/chsh.j2 new file mode 100644 index 00000000..37462f78 --- /dev/null +++ b/roles/ldap-client/templates/bin/chsh.j2 @@ -0,0 +1,4 @@ +#!/bin/sh +{{ ansible_header | comment }} +echo "Pour changer votre shell,\nAllez sur l'intranet : {{intranet_url}}" + diff --git a/roles/ldap-client/templates/bin/chsh.ldap.j2 b/roles/ldap-client/templates/bin/chsh.ldap.j2 new file mode 100644 index 00000000..175fdfc1 --- /dev/null +++ b/roles/ldap-client/templates/bin/chsh.ldap.j2 @@ -0,0 +1,4 @@ +#!/bin/sh +{{ ansible_header | comment }} +echo "Pour changer votre shell,\nAllez sur l'intranet : {{intranet_url}}" +echo "De toutes façons la vraie commande aurait pas marché, on installe pas nslcd-utils sur les serveurs normalement."