summaryrefslogtreecommitdiffstats
path: root/roles/openshift_hosted
diff options
context:
space:
mode:
authorAndrew Butcher <abutcher@afrolegs.com>2016-07-19 09:10:07 -0400
committerGitHub <noreply@github.com>2016-07-19 09:10:07 -0400
commita66b5026a4aff70fe38bb369d7cba0f7372725ef (patch)
treea080cdc5b9e21edaa7aa08f986f24e667b8530bf /roles/openshift_hosted
parent46ff071b63bc917a00922b4f93b149d9b334f92c (diff)
parentb83771910cde314d846ea9df3ac30ed826d5446f (diff)
downloadopenshift-a66b5026a4aff70fe38bb369d7cba0f7372725ef.tar.gz
openshift-a66b5026a4aff70fe38bb369d7cba0f7372725ef.tar.bz2
openshift-a66b5026a4aff70fe38bb369d7cba0f7372725ef.tar.xz
openshift-a66b5026a4aff70fe38bb369d7cba0f7372725ef.zip
Merge pull request #2173 from abutcher/warnings
Resolve some deprecation warnings.
Diffstat (limited to 'roles/openshift_hosted')
-rw-r--r--roles/openshift_hosted/tasks/router/router.yml11
1 files changed, 8 insertions, 3 deletions
diff --git a/roles/openshift_hosted/tasks/router/router.yml b/roles/openshift_hosted/tasks/router/router.yml
index c011db762..95f0617dc 100644
--- a/roles/openshift_hosted/tasks/router/router.yml
+++ b/roles/openshift_hosted/tasks/router/router.yml
@@ -9,10 +9,15 @@
module: slurp
src: "{{ item }}"
register: openshift_router_certificate_output
+ # Defaulting dictionary keys to none to avoid deprecation warnings
+ # (future fatal errors) during template evaluation. Dictionary keys
+ # won't be accessed unless openshift_hosted_router_certificate is
+ # defined and has all keys (certfile, keyfile, cafile) which we
+ # check above.
with_items:
- - "{{ openshift_hosted_router_certificate.certfile }}"
- - "{{ openshift_hosted_router_certificate.keyfile }}"
- - "{{ openshift_hosted_router_certificate.cafile }}"
+ - "{{ (openshift_hosted_router_certificate | default({'certfile':none})).certfile }}"
+ - "{{ (openshift_hosted_router_certificate | default({'keyfile':none})).keyfile }}"
+ - "{{ (openshift_hosted_router_certificate | default({'cafile':none})).cafile }}"
when: openshift_hosted_router_certificate is defined
- name: Persist certificate contents