andrewrothstein / ansible-anaconda

Ansible role for installing Anaconda
MIT License
47 stars 42 forks source link

Add `anaconda_umask` #39

Closed msabramo closed 2 years ago

msabramo commented 2 years ago

Allow setting a custom umask, because on some systems (e.g.: an Amazon Linux EC2 instance I'm testing with, the umask is set by default in /etc/profile to 027. This causes anaconda to get installed with the read and execute bits missing for world so normal users get errors when they try to use anaconda tools.

With this, I can use:

     - name: Include ansible-anaconda role
       include_role:
         name: ansible-anaconda
         apply:
           tags: anaconda
       vars:
         anaconda_make_sys_default: True
         anaconda_tmp_dir: "{{ ansible_env.HOME }}/tmp"
         anaconda_umask: '022'
       when: install_anaconda
       tags: anaconda

and anaconda gets installed so that it can be used by any user.

Note: This branch includes #38, because it touches the same lines and separating them would lead to merge conflicts. The "real" changes for this PR are in 781c8bc.

msabramo commented 2 years ago

Fixed merge conflict