X-Git-Url: https://freie-schul-it.de/gitweb/fsit_smgt.git/blobdiff_plain/dc8c574e8f50a671f13a70257fc35e1ad3d54078..6fceb0ba80d617e47871fdb17df783bf08cf903a:/tasks/cups.yml?ds=inline diff --git a/tasks/cups.yml b/tasks/cups.yml index a588a71..979736e 100644 --- a/tasks/cups.yml +++ b/tasks/cups.yml @@ -10,6 +10,10 @@ # https://github.com/OpenPrinting/cups/issues/158 ansible.builtin.command: cmd: cupsctl --no-remote-admin --no-remote-any --no-share-printers + register: cupsctl_no_remote_admin_response + changed_when: cupsctl_no_remote_admin_response.rc != 0 + when: cupsctl_no_remote_admin_response is defined + - name: cups settings ansible.builtin.command: cmd: cupsctl --remote-admin --remote-any --share-printers @@ -18,9 +22,9 @@ cmd: systemctl restart cups - name: create lpadmin user ansible.builtin.user: - name: {{ fsit_supolpadmin }} + name: "{{ fsit_smgt_lpadminuser }}" append: true groups: lpadmin update_password: always - password: "{{ lpadminuser|password_hash('sha512') }}" + password: "{{ fsit_smgt_lpadminuser_pw | password_hash('sha512') }}"