OpenJDK: remove the Oracle JDK packages, if there are any.
This commit is contained in:
parent
65dbfd8bee
commit
b00926c1d5
|
@ -21,3 +21,11 @@ openjdk_pkgs:
|
|||
# - jdk
|
||||
|
||||
oracle_jdk_ubuntu_ppa: 'ppa:webupd8team/java'
|
||||
openjdk_oracle_jdk_pkgs:
|
||||
- oracle-java7-installer
|
||||
- oracle-java7-set-default
|
||||
- oracle-java7-unlimited-jce-policy
|
||||
- oracle-java8-installer
|
||||
- oracle-java8-set-default
|
||||
- oracle-java8-unlimited-jce-policy
|
||||
|
|
@ -4,8 +4,8 @@
|
|||
apt_repository: repo='{{ dismissed_openjdk_ppa }}' update_cache=yes state=absent
|
||||
|
||||
- name: Remove the Oracle JDK PPA
|
||||
apt_repository: repo='{{ oracle_jdk_ubuntu_ppa }}' state=absent
|
||||
|
||||
apt_repository: repo='{{ oracle_jdk_ubuntu_ppa }}' state=absent update_cache=yes
|
||||
|
||||
- name: Check if we must use the Zulu repository
|
||||
set_fact:
|
||||
openjdk_zulu_repo_install: True
|
||||
|
@ -64,3 +64,10 @@
|
|||
when: openjdk_installed is changed
|
||||
|
||||
tags: [ 'jdk', 'openjdk' ]
|
||||
|
||||
- block:
|
||||
- name: Remove the Oracle JDK packages
|
||||
apt: pkg={{ openjdk_oracle_jdk_pkgs }} state=absent cache_valid_time=3600
|
||||
|
||||
tags: [ 'jdk', 'openjdk' ]
|
||||
|
||||
|
|
Loading…
Reference in New Issue