summaryrefslogtreecommitdiffstats
path: root/roles/bash/tasks/main.yml
blob: 4af7dc40be13bf3214581bef0779caf3f275e682 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
---
- name: "Ensure bash is installed"
  become: true
  ansible.builtin.package:
    name: "bash"
    state: "present"

- name: "Ensure .bash(rc|_profile) and .profile exists"
  # This is used by different setup scripts adding their init in one of these
  ansible.builtin.file:
    path: "{{ item }}"
    state: "touch"
    mode: "0644"
    modification_time: "preserve"
    access_time: "preserve"
  loop:
    - "{{ ansible_facts['env']['HOME'] }}/.bashrc"
    - "{{ ansible_facts['env']['HOME'] }}/.bash_profile"
    - "{{ ansible_facts['env']['HOME'] }}/.profile"