David K. Bainbridge | b541504 | 2016-05-13 17:06:10 -0700 | [diff] [blame] | 1 | --- |
| 2 | - name: Install add-apt-repository |
| 3 | sudo: yes |
alshabib | ecabc36 | 2016-05-23 22:18:11 -0700 | [diff] [blame] | 4 | apt: name=software-properties-common state=latest update_cache=yes |
David K. Bainbridge | b541504 | 2016-05-13 17:06:10 -0700 | [diff] [blame] | 5 | |
| 6 | - name: Add Oracle Java repository |
| 7 | sudo: yes |
David K. Bainbridge | 3b3fda0 | 2016-05-24 00:54:48 -0700 | [diff] [blame] | 8 | apt_repository: repo='ppa:webupd8team/java' update_cache=yes |
David K. Bainbridge | b541504 | 2016-05-13 17:06:10 -0700 | [diff] [blame] | 9 | |
| 10 | - name: Accept Java 8 license |
| 11 | sudo: yes |
| 12 | debconf: name='oracle-java8-installer' question='shared/accepted-oracle-license-v1-1' value='true' vtype='select' |
| 13 | |
| 14 | - name: Install Oracle Java 8 |
| 15 | sudo: yes |
| 16 | apt: name={{item}} state=latest |
| 17 | with_items: |
| 18 | - oracle-java8-installer |
| 19 | - ca-certificates |
| 20 | - oracle-java8-set-default |