瀏覽代碼

default to run on same host as postfixadmin

master
父節點
當前提交
6d258caab7
共有 2 個文件被更改,包括 6 次插入4 次删除
  1. +3
    -1
      defaults/main.yaml
  2. +3
    -3
      tasks/auth/sql.yaml

+ 3
- 1
defaults/main.yaml 查看文件

@@ -1,7 +1,9 @@
dovecot_postfixadmin_mysql_host: localhost
dovecot_postfixadmin_mysql_database: postfixadmin
dovecot_postfixadmin_mysql_username: dovecot
vmail_uid: 500
vmail_gid: 500
dovecot_lmtp_inet_listener: false
dovecot_unix_listeners_for_postfix: false
dovecot_unix_listeners_for_postfix: true
dovecot_auth_inet_listener: false
dovecot_auth: sql

+ 3
- 3
tasks/auth/sql.yaml 查看文件

@@ -3,7 +3,7 @@
- name: dovecot sql config
template:
src: dovecot-sql.conf.ext.j2
dest: /etc/dovecot/dovecot-sql.conf.ext.j2
dest: /etc/dovecot/dovecot-sql.conf.ext
notify:
- reload dovecot

@@ -12,6 +12,6 @@
name: "{{dovecot_postfixadmin_mysql_username}}"
password: "{{dovecot_postfixadmin_mysql_password}}"
priv: "{{dovecot_postfixadmin_mysql_database}}.*:SELECT"
host: "{{inventory_hostname}}"
host: "{{dovecot_postfixadmin_mysql_host}}"
state: present
delegate_to: "{{dovecot_postfixadmin_mysql_host}}"
delegate_to: "{{(dovecot_postfixadmin_mysql_host=='localhost')|ternary(inventory_hostname,dovecot_postfixadmin_mysql_host)}}"

Loading…
取消
儲存