Skip to content
Snippets Groups Projects
Commit 6cda204d authored by David Coutadeur's avatar David Coutadeur
Browse files

fix .htpasswd filename evaluation for webservice endpoints (#70)

parent d8f7fa36
No related branches found
No related tags found
No related merge requests found
......@@ -121,7 +121,7 @@
- name: Generate htpasswd files for webservices if they does not exist
ansible.builtin.shell:
cmd: |
if [ ! -f "/etc/lemonldap-ng/{{ item.key }}" ] && [ '{{ item.value.user }}' != "" ] && [ '{{ item.value.pass }}' != "" ];
if [ ! -f "/etc/lemonldap-ng/{{ item.key }}.htpasswd" ] && [ '{{ item.value.user }}' != "" ] && [ '{{ item.value.pass }}' != "" ];
then
htpasswd -bc '/etc/lemonldap-ng/{{ item.key }}.htpasswd' '{{ item.value.user }}' '{{ item.value.pass }}'
chmod 400 '/etc/lemonldap-ng/{{ item.key }}.htpasswd'
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment