diff --git a/postgresql/templates/pg_backup-default.j2 b/postgresql/templates/pg_backup-default.j2 index e7aae3d4..61648797 100644 --- a/postgresql/templates/pg_backup-default.j2 +++ b/postgresql/templates/pg_backup-default.j2 @@ -15,7 +15,11 @@ BUILD_DBLIST={{ pg_backup_build_db_list }} {% if pg_backup_db_list is defined %} DB_LIST="{{ pg_backup_db_list }}" {% else %} -DB_LIST="{% for db in psql_db_data %}{{ db.name }} {% endfor %}" +{% if psql_db_data is defined %} +DB_LIST="{% for db in psql_db_data %}{% if db.managedb is defined and db.managedb %}{{ db.name }} {% endif %}{% endfor %}" +{% else %} +DB_LIST="" +{% endif %} {% endif %} PG_USE_AUTH={{ pg_backup_use_auth }} PG_PASS_FILE={{ pg_backup_pass_file }}