Add initial Ubuntu workstation orchestration

This commit is contained in:
Fabio Scotto di Santolo
2026-03-23 22:04:25 +01:00
parent 60c995ca74
commit 6eb48e39ee
10 changed files with 126 additions and 14 deletions

View File

@@ -1 +1,9 @@
# variables for Ubuntu hosts
---
ubuntu_packages_base:
- ca-certificates
- curl
- gpg
- python3-apt
- python3-gi
- python3-gi-cairo
- software-properties-common

View File

@@ -1 +1,17 @@
# workstation profile variables
---
profile_packages:
- dbus-user-session
- gnome-keyring
- gnome-shell-extension-manager
- gnome-shell-extensions
- gnome-terminal
- gnome-tweaks
- seahorse
workstation_user_directories:
- path: "{{ user_home }}/.config"
mode: "0755"
- path: "{{ user_home }}/.local"
mode: "0755"
- path: "{{ user_home }}/.local/bin"
mode: "0755"

View File

@@ -1 +1,5 @@
# deadalus specific variables
---
hostname: deadalus
host_packages: []
host_enabled_services: []

View File

@@ -1,3 +1,4 @@
---
all:
children:
void:
@@ -14,6 +15,19 @@ all:
nymph:
ansible_connection: local
ubuntu:
children:
ubuntu_workstation:
ubuntu_server:
workstation:
children:
ubuntu_workstation:
server:
children:
ubuntu_server:
ubuntu_workstation:
hosts:
deadalus:

View File

@@ -1 +1,18 @@
# install packages with apt
---
- name: Refresh apt package cache
tags: [packages]
ansible.builtin.apt:
update_cache: true
cache_valid_time: 3600
- name: Install packages on Ubuntu
tags: [packages]
ansible.builtin.apt:
name: >-
{{
(common_packages | default([]))
+ (ubuntu_packages_base | default([]))
+ (profile_packages | default([]))
+ (host_packages | default([]))
}}
state: present

View File

@@ -1 +1,12 @@
# workstation profile tasks
---
- name: Ensure workstation user directories exist
tags: [dotfiles, dotfiles:workstation]
ansible.builtin.file:
path: "{{ item.path }}"
state: directory
owner: "{{ username }}"
group: "{{ user_group }}"
mode: "{{ item.mode }}"
loop: "{{ workstation_user_directories | default([]) }}"
loop_control:
label: "{{ item.path }}"

View File

@@ -1 +1,20 @@
# enable systemd services
---
- name: Enable base systemd services
tags: [services]
ansible.builtin.systemd:
name: "{{ item }}"
enabled: true
state: started
loop: "{{ enabled_services | default([]) }}"
loop_control:
label: "{{ item }}"
- name: Enable host systemd services
tags: [services]
ansible.builtin.systemd:
name: "{{ item }}"
enabled: true
state: started
loop: "{{ host_enabled_services | default([]) }}"
loop_control:
label: "{{ item }}"

View File

@@ -18,3 +18,11 @@
- packages_void
- services_runit
- profile_desktop_i3
- hosts: ubuntu_workstation
become: true
roles:
- packages_ubuntu
- services_systemd
- profile_workstation_gnome