mirror of
https://github.com/fscotto/infra.git
synced 2026-05-30 15:39:58 +00:00
Restrict tmux and desktop tools to Void hosts
This commit is contained in:
@@ -35,7 +35,7 @@ If any of these files appear later, treat them as higher-priority repo-local ins
|
|||||||
- Preserve idempotency and reproducibility
|
- Preserve idempotency and reproducibility
|
||||||
- Validate on one limited host before broad rollout
|
- Validate on one limited host before broad rollout
|
||||||
- Treat `secrets/` as sensitive; never print secret values
|
- Treat `secrets/` as sensitive; never print secret values
|
||||||
- Avoid editing vendored code under `dotfiles/common/.tmux/plugins/` unless explicitly asked
|
- Avoid editing vendored code under `dotfiles/desktop/.tmux/plugins/` unless explicitly asked
|
||||||
- Keep `ansible/site.yml` small; orchestration belongs there, implementation belongs in roles
|
- Keep `ansible/site.yml` small; orchestration belongs there, implementation belongs in roles
|
||||||
- Read the relevant inventory, vars, role tasks, templates, files, handlers, and dotfiles before editing
|
- Read the relevant inventory, vars, role tasks, templates, files, handlers, and dotfiles before editing
|
||||||
|
|
||||||
|
|||||||
@@ -25,7 +25,6 @@ common_packages:
|
|||||||
- fzf
|
- fzf
|
||||||
- git
|
- git
|
||||||
- jq
|
- jq
|
||||||
- tmux
|
|
||||||
- tree
|
- tree
|
||||||
- unzip
|
- unzip
|
||||||
- vim
|
- vim
|
||||||
@@ -42,18 +41,10 @@ common_dotfiles:
|
|||||||
src: .bash_profile
|
src: .bash_profile
|
||||||
dest: .bash_profile
|
dest: .bash_profile
|
||||||
mode: "0644"
|
mode: "0644"
|
||||||
- name: .tmux.conf
|
|
||||||
src: .tmux.conf
|
|
||||||
dest: .tmux.conf
|
|
||||||
mode: "0644"
|
|
||||||
- name: .vimrc
|
- name: .vimrc
|
||||||
src: .vimrc
|
src: .vimrc
|
||||||
dest: .vimrc
|
dest: .vimrc
|
||||||
mode: "0644"
|
mode: "0644"
|
||||||
- name: tmux config directory
|
|
||||||
src: .tmux/
|
|
||||||
dest: .tmux/
|
|
||||||
mode: preserve
|
|
||||||
- name: bat config
|
- name: bat config
|
||||||
src: .config/bat/.config/bat/
|
src: .config/bat/.config/bat/
|
||||||
dest: .config/bat/
|
dest: .config/bat/
|
||||||
|
|||||||
@@ -152,6 +152,14 @@ desktop_common_dotfiles:
|
|||||||
src: .themes.gitignore
|
src: .themes.gitignore
|
||||||
dest: .themes.gitignore
|
dest: .themes.gitignore
|
||||||
mode: "0644"
|
mode: "0644"
|
||||||
|
- name: .tmux.conf
|
||||||
|
src: .tmux.conf
|
||||||
|
dest: .tmux.conf
|
||||||
|
mode: "0644"
|
||||||
|
- name: tmux config directory
|
||||||
|
src: .tmux/
|
||||||
|
dest: .tmux/
|
||||||
|
mode: preserve
|
||||||
- name: Emacs config
|
- name: Emacs config
|
||||||
src: .emacs.d/
|
src: .emacs.d/
|
||||||
dest: .emacs.d/
|
dest: .emacs.d/
|
||||||
|
|||||||
@@ -33,6 +33,7 @@ void_packages_base:
|
|||||||
- seahorse
|
- seahorse
|
||||||
- socklog
|
- socklog
|
||||||
- socklog-void
|
- socklog-void
|
||||||
|
- tmux
|
||||||
- ufw
|
- ufw
|
||||||
- void-repo-nonfree
|
- void-repo-nonfree
|
||||||
- vpm
|
- vpm
|
||||||
|
|||||||
@@ -14,6 +14,7 @@
|
|||||||
group: "{{ effective_user_group }}"
|
group: "{{ effective_user_group }}"
|
||||||
mode: "0755"
|
mode: "0755"
|
||||||
loop: "{{ xdg_user_directories | default([]) }}"
|
loop: "{{ xdg_user_directories | default([]) }}"
|
||||||
|
when: "'void' in group_names"
|
||||||
|
|
||||||
- name: Copy common dotfiles
|
- name: Copy common dotfiles
|
||||||
tags: [dotfiles, dotfiles:common]
|
tags: [dotfiles, dotfiles:common]
|
||||||
|
|||||||
@@ -107,98 +107,6 @@
|
|||||||
}}
|
}}
|
||||||
state: present
|
state: present
|
||||||
|
|
||||||
- name: Set Ubuntu external tool release metadata
|
|
||||||
tags: [packages]
|
|
||||||
ansible.builtin.set_fact:
|
|
||||||
ubuntu_tools_tmp_dir: /tmp/ubuntu-tools
|
|
||||||
gitmux_version: v0.11.5
|
|
||||||
bw_version: 1.22.1
|
|
||||||
gitmux_arch: >-
|
|
||||||
{{
|
|
||||||
'amd64' if ansible_facts['architecture'] == 'x86_64'
|
|
||||||
else 'arm64' if ansible_facts['architecture'] in ['aarch64', 'arm64']
|
|
||||||
else ''
|
|
||||||
}}
|
|
||||||
|
|
||||||
- name: Ensure architecture is supported for gitmux binary
|
|
||||||
tags: [packages]
|
|
||||||
ansible.builtin.fail:
|
|
||||||
msg: "Unsupported architecture {{ ansible_facts['architecture'] }} for gitmux release binary"
|
|
||||||
when: gitmux_arch == ''
|
|
||||||
|
|
||||||
- name: Ensure architecture is supported for bw binary
|
|
||||||
tags: [packages]
|
|
||||||
ansible.builtin.fail:
|
|
||||||
msg: "Unsupported architecture {{ ansible_facts['architecture'] }} for bw release binary"
|
|
||||||
when: ansible_facts['architecture'] != 'x86_64'
|
|
||||||
|
|
||||||
- name: Ensure temporary directory exists for Ubuntu external tools
|
|
||||||
tags: [packages]
|
|
||||||
ansible.builtin.file:
|
|
||||||
path: "{{ ubuntu_tools_tmp_dir }}"
|
|
||||||
state: directory
|
|
||||||
mode: "0755"
|
|
||||||
|
|
||||||
- name: Set gitmux asset metadata
|
|
||||||
tags: [packages]
|
|
||||||
ansible.builtin.set_fact:
|
|
||||||
gitmux_asset: "gitmux_{{ gitmux_version }}_linux_{{ gitmux_arch }}.tar.gz"
|
|
||||||
|
|
||||||
- name: Download gitmux release archive
|
|
||||||
tags: [packages]
|
|
||||||
ansible.builtin.get_url:
|
|
||||||
url: "https://github.com/arl/gitmux/releases/download/{{ gitmux_version }}/{{ gitmux_asset }}"
|
|
||||||
dest: "{{ ubuntu_tools_tmp_dir }}/{{ gitmux_asset }}"
|
|
||||||
checksum: "sha256:https://github.com/arl/gitmux/releases/download/{{ gitmux_version }}/checksums.txt"
|
|
||||||
mode: "0644"
|
|
||||||
|
|
||||||
- name: Extract gitmux release archive
|
|
||||||
tags: [packages]
|
|
||||||
ansible.builtin.unarchive:
|
|
||||||
src: "{{ ubuntu_tools_tmp_dir }}/{{ gitmux_asset }}"
|
|
||||||
dest: "{{ ubuntu_tools_tmp_dir }}"
|
|
||||||
remote_src: true
|
|
||||||
|
|
||||||
- name: Install gitmux binary
|
|
||||||
tags: [packages]
|
|
||||||
ansible.builtin.copy:
|
|
||||||
src: "{{ ubuntu_tools_tmp_dir }}/gitmux"
|
|
||||||
dest: /usr/local/bin/gitmux
|
|
||||||
remote_src: true
|
|
||||||
owner: root
|
|
||||||
group: root
|
|
||||||
mode: "0755"
|
|
||||||
|
|
||||||
- name: Set bw asset metadata
|
|
||||||
tags: [packages]
|
|
||||||
ansible.builtin.set_fact:
|
|
||||||
bw_asset: "bw-linux-{{ bw_version }}.zip"
|
|
||||||
|
|
||||||
- name: Download bw release archive
|
|
||||||
tags: [packages]
|
|
||||||
ansible.builtin.get_url:
|
|
||||||
url: "https://github.com/bitwarden/cli/releases/download/v{{ bw_version }}/{{ bw_asset }}"
|
|
||||||
dest: "{{ ubuntu_tools_tmp_dir }}/{{ bw_asset }}"
|
|
||||||
checksum: "sha256:https://github.com/bitwarden/cli/releases/download/v{{ bw_version }}/bw-linux-sha256-{{ bw_version }}.txt"
|
|
||||||
mode: "0644"
|
|
||||||
|
|
||||||
- name: Extract bw release archive
|
|
||||||
tags: [packages]
|
|
||||||
ansible.builtin.unarchive:
|
|
||||||
src: "{{ ubuntu_tools_tmp_dir }}/{{ bw_asset }}"
|
|
||||||
dest: "{{ ubuntu_tools_tmp_dir }}"
|
|
||||||
remote_src: true
|
|
||||||
|
|
||||||
- name: Install bw binary
|
|
||||||
tags: [packages]
|
|
||||||
ansible.builtin.copy:
|
|
||||||
src: "{{ ubuntu_tools_tmp_dir }}/bw"
|
|
||||||
dest: /usr/local/bin/bw
|
|
||||||
remote_src: true
|
|
||||||
owner: root
|
|
||||||
group: root
|
|
||||||
mode: "0755"
|
|
||||||
|
|
||||||
- name: Add user to docker group
|
- name: Add user to docker group
|
||||||
tags: [packages]
|
tags: [packages]
|
||||||
ansible.builtin.user:
|
ansible.builtin.user:
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user