From: nicoo Date: Mon, 26 Nov 2018 22:30:58 +0000 (+0100) Subject: base: Refactor deployment of default config files X-Git-Url: https://git.realraum.at/?a=commitdiff_plain;h=a0813e951c5b91dc538803e9003f788d9ae80558;p=noc.git base: Refactor deployment of default config files --- diff --git a/ansible/roles/base/tasks/main.yml b/ansible/roles/base/tasks/main.yml index c155be4..e7e808e 100644 --- a/ansible/roles/base/tasks/main.yml +++ b/ansible/roles/base/tasks/main.yml @@ -148,19 +148,6 @@ when: ansible_distribution == "Ubuntu" -- name: install zshrc - with_items: - - src: "zprofile" - dest: "/etc/zsh/zprofile" - - src: "zshrc" - dest: "/etc/zsh/zshrc" - - src: "zshrc.skel" - dest: "/etc/skel/.zshrc" - copy: - src: "{{ item.src }}" - dest: "{{ item.dest }}" - mode: 0644 - - name: set root default shell to zsh user: name: root @@ -173,3 +160,16 @@ dest: /etc/adduser.conf regexp: "^#?{{ item.key }}=" line: "{{ item.key }}={{ item.value }}" + +- name: Deploy default configuration for tools + with_dict: + /etc/zsh/zprofile: zprofile + /etc/zsh/zshrc: zshrc + /etc/skel/.zshrc: zshrc.skel + + loop_control: + label: "{{ item.key }}" + copy: + mode: 0644 + src: "{{ item.value }}" + dest: "{{ item.key }}"