From 080bff7b3dc43a8720c6c5f8a493a1ca3d13de33 Mon Sep 17 00:00:00 2001 From: N Date: Mon, 15 Apr 2019 00:26:32 +0100 Subject: [PATCH] Always retry alternatives.install state --- postgres/client/init.sls | 3 +++ postgres/dev/init.sls | 3 +++ postgres/server/init.sls | 3 +++ 3 files changed, 9 insertions(+) diff --git a/postgres/client/init.sls b/postgres/client/init.sls index 67246376..041c1057 100644 --- a/postgres/client/init.sls +++ b/postgres/client/init.sls @@ -39,6 +39,9 @@ postgresql-{{ bin }}-altinstall: - onlyif: test -f {{ path }} - require: - pkg: postgresql-client-libs + - retry: + attempts: 2 + until: True {%- endfor %} {%- endif %} diff --git a/postgres/dev/init.sls b/postgres/dev/init.sls index 09b43235..20854065 100644 --- a/postgres/dev/init.sls +++ b/postgres/dev/init.sls @@ -27,6 +27,9 @@ postgresql-{{ bin }}-altinstall: - onlyif: alternatives --display {{ bin }} {% else %} - onlyif: test -f {{ path }} + - retry: + attempts: 2 + until: True {% endif %} {%- endfor %} diff --git a/postgres/server/init.sls b/postgres/server/init.sls index d9a54097..2ef98dd7 100644 --- a/postgres/server/init.sls +++ b/postgres/server/init.sls @@ -54,6 +54,9 @@ postgresql-{{ bin }}-altinstall: - pkg: postgresql-server - require_in: - cmd: postgresql-cluster-prepared + - retry: + attempts: 2 + until: True {%- endfor %} {%- endif %}