forked from rc/classroom
43 lines
1.2 KiB
YAML
43 lines
1.2 KiB
YAML
- name: Set Matlab version and destination
|
|
set_fact:
|
|
target_version: "R2025a_Update_1"
|
|
license_path: \\ucilnicesmb.fri1.uni-lj.si\ucilnice_d\install\matlab\network.lic
|
|
dest_dir: C:\matlab
|
|
|
|
- name: Set ISO path
|
|
set_fact:
|
|
iso_path: "{{ installers }}\\matlab\\{{ target_version }}_Windows.iso"
|
|
|
|
- name: Mount Matlab ISO
|
|
win_disk_image:
|
|
image_path: "{{ iso_path }}"
|
|
state: present
|
|
register: disk_image
|
|
|
|
- name: Prepare installer_input.txt
|
|
template:
|
|
src: installer_input.txt
|
|
dest: c:\matlab_installer_input.txt
|
|
|
|
- name: Install Matlab
|
|
win_package:
|
|
path: "{{ disk_image.mount_paths[0] }}\\setup.exe"
|
|
arguments: -inputFile "c:\\matlab_installer_input.txt"
|
|
|
|
- name: Unmount Matlab ISO
|
|
win_disk_image:
|
|
image_path: "{{ iso_path }}"
|
|
state: absent
|
|
ignore_errors: true
|
|
|
|
- name: Create licenses directory
|
|
win_file:
|
|
dest: "{{ dest_dir }}\\licenses"
|
|
state: directory
|
|
|
|
# MATLAB will no longer be used with concurrent licenses - let them license their own!
|
|
#- name: Install Matlab license
|
|
# win_copy:
|
|
# dest: "{{ dest_dir }}\\licenses\\network.lic"
|
|
# src: "{{ installers }}\\matlab\\network.lic"
|
|
# remote_src: yes
|