create tasks for cron extension

This commit is contained in:
Tobias Lehmann 2024-04-16 13:32:07 +02:00
parent 9f6ea29148
commit af7a3a548d

View File

@ -41,10 +41,14 @@
name: postgresql
state: restarted
- postgresql_query:
db: {{ timescaledb_database_name }}
login_user: postgres
login_password: {{ postgresql_admin_password }}
- name: "Configure pg_cron extension"
tags:
- install
- timescaledb_install
postgresql_query:
db: "{{ timescaledb_database_name }}"
login_user: "postgres"
login_password: "{{ postgresql_admin_password }}"
query:
- CREATE EXTENSION pg_cron;
- GRANT USAGE ON SCHEMA cron TO {{ timescaledb_database_user }};