1
Fork 0
theorangeone.net-legacy/content/projects/dotfiles.md

29 lines
1.9 KiB
Markdown
Raw Permalink Normal View History

2017-05-06 19:02:49 +01:00
---
title: My Dotfiles
repo: RealOrangeOne/dotfiles
2017-09-19 13:32:52 +01:00
tags: [arch, linux]
2017-05-06 19:02:49 +01:00
---
2020-05-31 11:37:48 +01:00
[Dotfiles](https://wiki.archlinux.org/index.php/Dotfiles) are a way for people to store settings and preferences to make setting up a new computer that much easier. I use both my laptop, desktop and work machine almost every day, and want them to be set up in an almost identical way.
2017-05-06 19:02:49 +01:00
2020-05-31 11:37:48 +01:00
Most people store their dotfiles in version control. This is a great solution as it's possible to add authentication before accessing them, and stores a complete version history. It also means they're public.
2017-05-06 19:02:49 +01:00
2018-10-14 11:55:06 +01:00
## _My_ Dotfiles
2020-05-31 11:37:48 +01:00
[My Dotfiles](https://github.com/RealOrangeOne/dotfiles) are built using [Ansible](https://www.ansible.com/). Ansible is an open-source configuration management tool designed to help administer many servers with a single configuration. As people started using Ansible for configuration of the local machine (as I am), Ansible made some optimizations so commands run better locally.
2017-05-06 19:02:49 +01:00
2020-05-31 11:37:48 +01:00
I synchronize these files with git, and publish them [on GitHub](https://github.com/RealOrangeOne/dotfiles).
2018-10-14 11:55:06 +01:00
### Previous iterations
2019-06-05 20:25:49 +01:00
Previously, my dotfiles used [puppet](https://puppet.com/), which is fairly overkill for what I'm using it for, and was incredibly complicated compared to Ansible. Ansible bought with it many other benefits:
2018-10-14 11:55:06 +01:00
- Simpler configuration. YAML vs Puppet
- Wider variety of 1st party modules
- Easier to pin dependencies, as it's installed through `pip`
- Much nicer templating. Jinja2 vs ERB
- Much simpler support for running commands multiple times with [`with_items`](https://docs.ansible.com/ansible/2.5/plugins/lookup/items.html)
- Dry-run support, for validation on a CI
2017-05-06 19:02:49 +01:00
2017-12-28 16:29:36 +00:00
### Private data
2018-10-14 11:55:06 +01:00
Things like SSH config and private environment variables can't go onto GitHub, for obvious reasons. For this, I use my [nextcloud](https://nextcloud.com/) server to sync a private directory to my machines, and depend on those files in the config.