set the tomcat version at runtime. See https://support.d4science.org/issues/16551
This commit is contained in:
parent
19b37c6d4c
commit
f12038b2f1
|
@ -1,5 +1,8 @@
|
||||||
---
|
---
|
||||||
tomcat_version: 7
|
# The tomcat version is set at runtime. It changes from one distribution to the other.
|
||||||
|
#tomcat_version: 7
|
||||||
|
# To force a tomcat version set the following variable:
|
||||||
|
# tomcat_fixed_version: 9
|
||||||
tomcat_pkg_state: present
|
tomcat_pkg_state: present
|
||||||
tomcat_service_enabled: True
|
tomcat_service_enabled: True
|
||||||
tomcat_pkgs:
|
tomcat_pkgs:
|
||||||
|
|
|
@ -1,4 +1,26 @@
|
||||||
---
|
---
|
||||||
|
- name: Set the tomcat version for ubuntu Trusy
|
||||||
|
set_fact:
|
||||||
|
tomcat_version: 7
|
||||||
|
when:
|
||||||
|
- ansible_distribution_major_version <= '16'
|
||||||
|
- tomcat_fixed_version is not defined
|
||||||
|
tags: tomcat
|
||||||
|
|
||||||
|
- name: Set the tomcat version for Ubuntu bionic
|
||||||
|
set_fact:
|
||||||
|
tomcat_version: 8
|
||||||
|
when:
|
||||||
|
- ansible_distribution_major_version == '18'
|
||||||
|
- tomcat_fixed_version is not defined
|
||||||
|
tags: tomcat
|
||||||
|
|
||||||
|
- name: Impose a tomcat version
|
||||||
|
set_fact:
|
||||||
|
tomcat_version: '{{ tomcat_fixed_version }}'
|
||||||
|
when: tomcat_fixed_version is defined
|
||||||
|
tags: tomcat
|
||||||
|
|
||||||
- name: Install the tomcat packages
|
- name: Install the tomcat packages
|
||||||
apt: pkg={{ tomcat_pkgs }} state={{ tomcat_pkg_state }}
|
apt: pkg={{ tomcat_pkgs }} state={{ tomcat_pkg_state }}
|
||||||
tags: tomcat
|
tags: tomcat
|
||||||
|
|
Loading…
Reference in New Issue