diff --git a/defaults/main.yml b/defaults/main.yml index 4ec9eb7..fcc9e34 100644 --- a/defaults/main.yml +++ b/defaults/main.yml @@ -35,7 +35,8 @@ odoo_reportlab_font_url: http://www.reportlab.com/ftp/pfbfer.zip # Tasks related to PostgreSQL odoo_postgresql_set_user: True odoo_postgresql_user_role_attr: CREATEDB,NOSUPERUSER -odoo_postgresql_active_unaccent: True +odoo_postgresql_extensions: + - unaccent # Standard installation/configuration options (odoo_install_type == 'standard') odoo_config_file: "/home/{{ odoo_user }}/{{ odoo_service }}.conf" diff --git a/tasks/postgresql.yml b/tasks/postgresql.yml index c4d6261..250c72d 100644 --- a/tasks/postgresql.yml +++ b/tasks/postgresql.yml @@ -18,9 +18,11 @@ when: odoo_config_db_passwd is defined and odoo_config_db_passwd and odoo_postgresql_set_user - - name: PostgreSQL - Activate the 'unaccent' extension on databases - postgresql_ext: name=unaccent db=template1 - when: odoo_postgresql_active_unaccent + - name: PostgreSQL - Activate some extensions on the 'template1' database + postgresql_ext: + name: "{{ item }}" + db: template1 + with_items: "{{ odoo_postgresql_extensions }}" delegate_to: "{{ odoo_postgresql_delegate_to }}" remote_user: "{{ odoo_postgresql_remote_user }}"