determine_version.yaml 749 B

1234567891011121314151617
  1. ---
  2. # debating making this a module instead?
  3. - fail:
  4. msg: Missing version to install provided by 'openshift_logging_kibana_image_version'
  5. when: not openshift_logging_kibana_image_version or openshift_logging_kibana_image_version == ''
  6. - set_fact:
  7. kibana_version: "{{ __latest_kibana_version }}"
  8. when: openshift_logging_kibana_image_version == 'latest'
  9. # should we just assume that we will have the correct major version?
  10. - set_fact: kibana_version="{{ openshift_logging_kibana_image_version | regex_replace('^v?(?P<major>\d)\.(?P<minor>\d).*$', '3_\\g<minor>') }}"
  11. when: openshift_logging_kibana_image_version != 'latest'
  12. - fail:
  13. msg: Invalid version specified for Kibana
  14. when: kibana_version not in __allowed_kibana_versions