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 c6f15305..8481ba64 100644 --- a/postgres/server/init.sls +++ b/postgres/server/init.sls @@ -18,8 +18,10 @@ 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 {%- endif %} {%- if postgres.fromrepo %} - fromrepo: {{ postgres.fromrepo }} diff --git a/postgres/upstream.sls b/postgres/upstream.sls index db108ee4..0fe9ff9c 100644 --- a/postgres/upstream.sls +++ b/postgres/upstream.sls @@ -28,8 +28,6 @@ postgresql-repo: {{- format_kwargs(postgres.pkg_repo) }} - require: - pkg: postgresql-pkg-deps - - require_in: - - pkg: postgresql-server {%- else -%}