From 57f0d62d05ba938f5922d6bb4b63e35785c2d96f Mon Sep 17 00:00:00 2001 From: Keshav Prasad Date: Tue, 6 Sep 2022 21:29:47 +0530 Subject: [PATCH] fix: ignore errors for missing pods --- kubernetes/ansible/roles/kong-api/tasks/main.yml | 3 ++- kubernetes/ansible/roles/kong-consumer/tasks/main.yml | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/kubernetes/ansible/roles/kong-api/tasks/main.yml b/kubernetes/ansible/roles/kong-api/tasks/main.yml index d85575dece..5b9ff4d8a2 100644 --- a/kubernetes/ansible/roles/kong-api/tasks/main.yml +++ b/kubernetes/ansible/roles/kong-api/tasks/main.yml @@ -23,4 +23,5 @@ shell: "python /tmp/kong-api-scripts/kong_apis.py /tmp/kong_apis.json --kong-admin-api-url=http://{{ private_ingressgateway_ip }}/admin-api" - name: Reload kong - shell: kubectl get pod -l app=apimanager --namespace={{namespace}} -o name | xargs -I{} kubectl exec {} -- kong reload \ No newline at end of file + shell: kubectl get pod -l app=apimanager --namespace={{namespace}} -o name | xargs -I{} kubectl exec {} -- kong reload + ignore_errors: true diff --git a/kubernetes/ansible/roles/kong-consumer/tasks/main.yml b/kubernetes/ansible/roles/kong-consumer/tasks/main.yml index edb1b4c0a4..f7772d2699 100644 --- a/kubernetes/ansible/roles/kong-consumer/tasks/main.yml +++ b/kubernetes/ansible/roles/kong-consumer/tasks/main.yml @@ -50,4 +50,5 @@ - /tmp/jwt_token.txt - name: Reload kong - shell: kubectl get pod -l app=apimanager --namespace={{namespace}} -o name | xargs -I{} kubectl exec {} -- kong reload \ No newline at end of file + shell: kubectl get pod -l app=apimanager --namespace={{namespace}} -o name | xargs -I{} kubectl exec {} -- kong reload + ignore_errors: true