--- - hosts: "{{ variable_host | default(lab15_standard) }}" gather_facts: no become: yes tasks: - name: add matlab alias to /etc/bash.bashrc lineinfile: path: /etc/bash.bashrc line: 'alias matlab="matlab -desktop -softwareopengl"' - name: add -softwareopengl to gnome icon ini_file: path: /usr/share/applications/matlab.desktop section: Desktop Entry option: Exec value: matlab -desktop -softwareopengl backup: yes no_extra_spaces: yes