From 37f344bd1ac8e01e90e8a9d8e9dae49fc917a775 Mon Sep 17 00:00:00 2001 From: Tobias Lehmann Date: Tue, 16 Apr 2024 10:47:05 +0200 Subject: [PATCH] added encoding --- roles/common/tasks/common.yml | 39 +++++++---------------------------- 1 file changed, 7 insertions(+), 32 deletions(-) diff --git a/roles/common/tasks/common.yml b/roles/common/tasks/common.yml index a40a36c..80b588e 100644 --- a/roles/common/tasks/common.yml +++ b/roles/common/tasks/common.yml @@ -1,32 +1,7 @@ - - name: LANG in '.profile' für root analog Locale setzen - tags: always - lineinfile: - path: /root/.profile - regexp: '^export LANG=en_US.UTF-8' - line: 'export LANG=en_US.UTF-8' - state: present - - - name: LANG in '.profile' für root analog Locale setzen - tags: always - lineinfile: - path: /root/.profile - regexp: '^export LANG=de_DE.UTF-8' - line: 'export LANG=de_DE.UTF-8' - state: present - - - name: LANG in '.profile' für Benutzer ansible analog Locale setzen - tags: always - lineinfile: - path: /home/ansible/.profile - regexp: '^export LANG=en_US.UTF-8' - line: 'export LANG=en_US.UTF-8' - state: present - - - - name: LANG in '.profile' für Benutzer ansible analog Locale setzen - tags: always - lineinfile: - path: /home/ansible/.profile - regexp: '^export LANG=de_DE.UTF-8' - line: 'export LANG=de_DE.UTF-8' - state: present + - name: ensure locales exist + locale_gen: + name: '{{ item }}' + state: present + loop: + - en_US.UTF-8 + - de_DE.UTF-8