ajoute les archives
This commit is contained in:
@@ -0,0 +1,63 @@
|
||||
---
|
||||
- name: Check input variable
|
||||
ansible.builtin.fail:
|
||||
msg: |
|
||||
la variable zimbraMailDomain est obligatoire pour
|
||||
utiliser le role set-logo.
|
||||
Veuillez la rajouter dans les host_vars
|
||||
when:
|
||||
- zimbraMailDomain is not defined
|
||||
|
||||
- name: Check param - zmprov gd zimbraPublicServiceHostname
|
||||
ansible.builtin.shell: |
|
||||
set -e -o pipefail
|
||||
/opt/zimbra/bin/zmprov gd {{ zimbraMailDomain }} zimbraPublicServiceHostname | sed -n 2p | awk '{print $2}'
|
||||
register: zps_hostname
|
||||
changed_when: false
|
||||
args:
|
||||
executable: /bin/bash
|
||||
|
||||
- name: Stop run if zimbraPublicServiceHostname param not set
|
||||
ansible.builtin.fail:
|
||||
msg: |
|
||||
Veuillez d'abord renseigner
|
||||
la configuration zimbraPublicServiceHostname
|
||||
du domaine {{ zimbraMailDomain }}
|
||||
when:
|
||||
- zps_hostname.stdout == ""
|
||||
|
||||
- name: Check param - zmprov gd zimbraPublicServiceProtocol
|
||||
ansible.builtin.shell: |
|
||||
set -e -o pipefail
|
||||
/opt/zimbra/bin/zmprov gd {{ zimbraMailDomain }} zimbraPublicServiceProtocol | sed -n 2p | awk '{print $2}'
|
||||
register: zps_protocol
|
||||
changed_when: false
|
||||
args:
|
||||
executable: /bin/bash
|
||||
|
||||
- name: Stop run if zimbraPublicServiceProtocol param not set
|
||||
ansible.builtin.fail:
|
||||
msg: |
|
||||
Veuillez d'abord renseigner
|
||||
la configuration zimbraPublicServiceProtocol
|
||||
du domaine {{ zimbraMailDomain }}
|
||||
when:
|
||||
- zps_protocol.stdout == ""
|
||||
|
||||
- name: Check param - zmprov gd zimbraPublicServicePort
|
||||
ansible.builtin.shell: |
|
||||
set -e -o pipefail
|
||||
/opt/zimbra/bin/zmprov gd {{ zimbraMailDomain }} zimbraPublicServicePort | sed -n 2p | awk '{print $2}'
|
||||
register: zps_port
|
||||
changed_when: false
|
||||
args:
|
||||
executable: /bin/bash
|
||||
|
||||
- name: Stop run if zimbraPublicServicePort param not set
|
||||
ansible.builtin.fail:
|
||||
msg: |
|
||||
Veuillez d'abord renseigner
|
||||
la configuration zimbraPublicServicePort
|
||||
du domaine {{ zimbraMailDomain }}
|
||||
when:
|
||||
- zps_port.stdout == ""
|
||||
@@ -0,0 +1,11 @@
|
||||
---
|
||||
- name: Check required parameters
|
||||
include_tasks: check_param.yml
|
||||
|
||||
- name: Set zextras login page
|
||||
ansible.builtin.command: "/opt/zimbra/bin/zmprov
|
||||
md {{ zimbraMailDomain }} \
|
||||
zimbraAuthMech custom:zx \
|
||||
zimbraWebClientLoginURL /zx/login/page/?domain={{ zimbraMailDomain }} \
|
||||
zimbraWebClientLogoutURL /zx/auth/logout/"
|
||||
changed_when: true
|
||||
Reference in New Issue
Block a user