Skip to content

AntonVanAssche/Dotfiles

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Banner
A bunch of files that start with `.` and makes linux more awesome!

The files in this repository are the configuration settings for the tools I use regularly. They are specifically created to function seamlessly on Fedora Linux, but can be conveniently customized to suit other distributions.

Table of Contents

Setup Info

preview

Here are some details about my setup:

Installation

Prerequisites

Ensure that you have Ansible installed on a server/desktop, which serves as the control node. This may also be localhost, but I prefer to use a separate server/desktop to manage my dotfiles.

$ sudo dnf install ansible

Once Ansible is installed, it's time to install all roles this playbook relies on.

$ ansible-galaxy install -r ansible/requirements.yml

Inventory

Create an inventory file (e.g. ansible/inventory.yml) with the following contents:

servers:
  vars:
    ansible_user: <username>
    ansible_become: true
  hosts:
    fedorable:
      ansible_host: <ip_address>
      ansible_ssh_private_key_file: "{{ ansible_env.HOME }}/.ssh/<ssh_private_key>/"

Configuration

Ensure to customize each role by creating host-specific configuration files. Use ansible/host_vars/fedorable.yml as a starting point, and replicate the filename for each host (e.g., bob.yml for a host named bob).

When configuring local hosts, ensure the configuration file is called localhost.yml.

Currently, the following custom roles used:

  • Base: This role installs a bunch of packages and configures some basic settings, and installs a bunch of packages.
  • Gnome: This role installs and configures the desktop experience, by applying themes, conky widgets, and more.
  • (WIP) Bspwm: THis role is disabled by default, simply uncomment it within the init.yml playbook. Ths role installs all required packages, installs the configuration files, and more.

Ansible Vault (Sensitive Vars)

Create an Ansible vault to securely store the ansible_become_pass variable.

$ ansible-vault create ansible/vaulted_vars.yml

Add sensitive information to the vault, and save the file.

ansible_become_pass: "<password>"

Usage

Run the Ansible playbook to apply the configurations:

$ ansible-playbook -i ansible/inventory.yml ansible/init.yml --ask-vault-pass

Updating

Since most configuration files are installed by using symbolic links to the original files, updating the dotfiles is as easy as pulling the latest changes from this repository.

$ git pull origin master

However, some configuration files are not installed by using symbolic links, but by rerunning the Ansible playbook theses files will be updated as well.

$ git pull origin master