diff --git a/roles/classroom/tasks/main.yml b/roles/classroom/tasks/main.yml index 5ff0c8a..262f3db 100644 --- a/roles/classroom/tasks/main.yml +++ b/roles/classroom/tasks/main.yml @@ -1,3 +1,6 @@ +# must come before netbeans +- import_tasks: openjdk.yml + - import_tasks: 7zip.yml - import_tasks: audacity.yml - import_tasks: blender.yml @@ -12,7 +15,6 @@ - import_tasks: netbeans.yml - import_tasks: notepad++.yml - import_tasks: octave.yml -- import_tasks: openjdk.yml - import_tasks: orange.yml - import_tasks: pelles-c.yml - import_tasks: processing.yml diff --git a/roles/classroom/tasks/netbeans.yml b/roles/classroom/tasks/netbeans.yml index 0e4e49b..586bc69 100644 --- a/roles/classroom/tasks/netbeans.yml +++ b/roles/classroom/tasks/netbeans.yml @@ -1,4 +1,9 @@ +- name: Set Netbeans version + set_fact: + target_version: "15" + - name: Install Netbeans win_package: - path: "https://github.com/codelerity/netbeans-installers/releases/download/v15-build1/Apache-NetBeans-15.exe" - arguments: /VerySilent + path: "https://dlcdn.apache.org/netbeans/netbeans-installers/{{ target_version }}/Apache-NetBeans-{{ target_version }}-bin-windows-x64.exe" + arguments: --silent + creates_path: "%ProgramFiles%\\NetBeans-{{ target_version }}\\netbeans\\bin\\netbeans.exe" diff --git a/roles/classroom/tasks/openjdk.yml b/roles/classroom/tasks/openjdk.yml index ffc6a05..4d74a8a 100644 --- a/roles/classroom/tasks/openjdk.yml +++ b/roles/classroom/tasks/openjdk.yml @@ -1,3 +1,14 @@ +- name: Set OpenJDK version + set_fact: + target_version: "19.0.0" + - name: Install OpenJDK win_chocolatey: name: openjdk + version: "{{ target_version }}" + +- name: Set JAVA_HOME + win_environment: + name: JAVA_HOME + value: "C:\\Program Files\\OpenJDK\\jdk-{{ target_version | regex_search('\\d+') }}" + level: machine