roundcube: create tables just on db create

This commit is contained in:
genofire 2020-07-24 18:42:26 +02:00
parent 3b6a2f7004
commit e1ee1f7b55
2 changed files with 3 additions and 2 deletions

View File

@ -35,7 +35,6 @@ mailserver_mailman_domains:
mailserver_roundcubemail_enabled: true mailserver_roundcubemail_enabled: true
mailserver_roundcubemail_domain: "" mailserver_roundcubemail_domain: ""
mailserver_roundcubemail_enabled_installer: false mailserver_roundcubemail_enabled_installer: false
mailserver_roundcubemail_db_create_schema: false # run once with true
mailserver_roundcubemail_db_type: "pgsql" mailserver_roundcubemail_db_type: "pgsql"
mailserver_roundcubemail_db_host: "localhost" mailserver_roundcubemail_db_host: "localhost"
mailserver_roundcubemail_db_name: "roundcubemail" mailserver_roundcubemail_db_name: "roundcubemail"

View File

@ -10,6 +10,7 @@
password: "{{ mailserver_roundcubemail_db_password }}" password: "{{ mailserver_roundcubemail_db_password }}"
- name: roundcubemail - create database - name: roundcubemail - create database
register: mailserver_roundcubemail_db_create
postgresql_db: postgresql_db:
login_host: "{{ mailserver_roundcubemail_db_host }}" login_host: "{{ mailserver_roundcubemail_db_host }}"
name: "{{ mailserver_roundcubemail_db_name }}" name: "{{ mailserver_roundcubemail_db_name }}"
@ -19,8 +20,9 @@
lc_ctype: en_US.UTF-8 lc_ctype: en_US.UTF-8
# TODO maybe notify
- name: roundcubemail - create tables - name: roundcubemail - create tables
when: mailserver_roundcubemail_db_create_schema when: mailserver_roundcubemail_db_create.changed
postgresql_query: postgresql_query:
login_host: "{{ mailserver_roundcubemail_db_host }}" login_host: "{{ mailserver_roundcubemail_db_host }}"
login_user: "{{ mailserver_roundcubemail_db_user }}" login_user: "{{ mailserver_roundcubemail_db_user }}"