Feat: dotfiles deployement tested and works
This commit is contained in:
@@ -1,18 +0,0 @@
|
||||
---
|
||||
- name: Create NAS share directory
|
||||
file:
|
||||
path: "/media/{{ item.host }}"
|
||||
state: directory
|
||||
with_items: "{{ autofs }}"
|
||||
|
||||
- name: Activate NAS shares for autofs
|
||||
lineinfile:
|
||||
path: /etc/autofs/auto.master
|
||||
line: "/media/{{ item.host }} /etc/autofs/auto.{{ item.host }} --timeout=60 --browse"
|
||||
with_items: "{{ autofs }}"
|
||||
|
||||
- name: NAS autofs config file
|
||||
template:
|
||||
src: "files/autofs.{{ item.host }}"
|
||||
dest: "/etc/autofs/auto.{{ item.host }}"
|
||||
with_items: "{{ autofs }}"
|
||||
@@ -10,23 +10,24 @@
|
||||
- name: Clone dotfiles
|
||||
ansible.builtin.git:
|
||||
repo: 'https://git.opytex.org/lafrite/dotfiles.git'
|
||||
dest: ~/.dotfiles
|
||||
become: true
|
||||
become_user: "{{ me.username }}"
|
||||
dest: "/home/{{ username }}/.dotfiles"
|
||||
become: yes
|
||||
|
||||
- name: user owns its dotfiles
|
||||
ansible.builtin.file:
|
||||
path: "/home/{{ username }}/.dotfiles"
|
||||
owner: "{{ username }}"
|
||||
become: yes
|
||||
|
||||
- name: stow configs
|
||||
ansible.builtin.command:
|
||||
cmd: stow {{ item }}
|
||||
chdir: ~/.dotfiles/
|
||||
chdir: "/home/{{ username }}/.dotfiles"
|
||||
with_items: "{{ config2stow }}"
|
||||
become: true
|
||||
become_user: "{{ me.username}}"
|
||||
|
||||
- name: home mounts
|
||||
import_tasks: home_mounts.yml
|
||||
become: yes
|
||||
|
||||
- name: Gnome config
|
||||
import_tasks: gnome.yml
|
||||
become: true
|
||||
become_user: "{{ me.username }}"
|
||||
#become: true
|
||||
become_user: "{{ username }}"
|
||||
when: no # soucis avec la version de psutil
|
||||
|
||||
Reference in New Issue
Block a user