From 26b223323fa65abee731af04ee9631062a78b308 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javier=20B=C3=A9rtoli?= Date: Fri, 26 Feb 2021 06:53:10 -0300 Subject: [PATCH] fix(repo): check whether pkg_repo is set --- postgres/client/init.sls | 2 +- postgres/python.sls | 2 +- postgres/server/init.sls | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/postgres/client/init.sls b/postgres/client/init.sls index 839eecd0..bfaacfc9 100644 --- a/postgres/client/init.sls +++ b/postgres/client/init.sls @@ -16,7 +16,7 @@ include: postgresql-client-libs: pkg.installed: - pkgs: {{ pkgs | json }} - {%- if postgres.use_upstream_repo == true %} + {%- if 'pkg_repo' in postgres and postgres.use_upstream_repo == true %} - refresh: True - require: - pkgrepo: postgresql-repo diff --git a/postgres/python.sls b/postgres/python.sls index 58d0fbbb..d00a153c 100644 --- a/postgres/python.sls +++ b/postgres/python.sls @@ -9,7 +9,7 @@ postgresql-python: {% if postgres.fromrepo %} - fromrepo: {{ postgres.fromrepo }} {% endif %} - {% if postgres.use_upstream_repo == true %} + {% if 'pkg_repo' in postgres and postgres.use_upstream_repo == true %} - refresh: True - require: - pkgrepo: postgresql-repo diff --git a/postgres/server/init.sls b/postgres/server/init.sls index ce1d5753..8481ba64 100644 --- a/postgres/server/init.sls +++ b/postgres/server/init.sls @@ -18,7 +18,7 @@ include: postgresql-server: pkg.installed: - pkgs: {{ pkgs | json }} -{%- if postgres.use_upstream_repo == true %} +{%- if 'pkg_repo' in postgres and postgres.use_upstream_repo == true %} - refresh: True - require: - pkgrepo: postgresql-repo