Skip to content

Commit a117107

Browse files
author
Derek
committed
feat: Refactor to tag-based options, fix GNOME extensions, update Ghostty config
- Refactor install.sh to use --tags/--tags-exclude instead of -e extra vars - Fix winlike/maclike to be mutually exclusive (only one style installs) - Fix GNOME extension installation to use correct user home directory - Fix RDP certificate ownership (gnome-remote-desktop user) - Remove deprecated gtk-adwaita option from Ghostty config (removed in 1.2.0) - Update README with new tag-based installation documentation - Add STATE.md session notes
1 parent 3473198 commit a117107

20 files changed

Lines changed: 6779 additions & 643 deletions

README.md

Lines changed: 53 additions & 101 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,7 @@ Standardised complete developer environment setup for HyperSec DFE developers ac
1111

1212
## Platform Support
1313

14-
- **[Multi-Platform (Recommended)](#multi-platform-quick-start)** - Ansible-based setup for Fedora, Ubuntu, and macOS
15-
- **[Fedora Linux (Legacy)](#fedora-linux-legacy)** - Shell script-based setup (bug fixes only)
14+
- **[Multi-Platform (Recommended)](#multi-platform-quick-start)** - Ansible-based setup for Ubuntu, Fedora, and macOS
1615
- **[Windows 11](#windows-11-soe)** - Productivity and VM host setup with Hyper-V
1716

1817
## Multi-Platform Quick Start
@@ -32,54 +31,64 @@ cd dfe-developer
3231
# Install with core developer tools
3332
./install.sh --core
3433

35-
# Install everything (base + core + VM + RDP optimizers)
34+
# Install everything (base + core + VM + RDP + winlike desktop)
3635
./install.sh --all
3736

38-
# Other options:
39-
./install.sh --no-ghostty # Skip Ghostty terminal
40-
./install.sh --vm # Add VM optimizations (Linux only)
41-
./install.sh --rdp # Add RDP optimizations (Linux only)
42-
./install.sh --check # Dry-run (no changes)
37+
# Include Windows-style GNOME desktop (bottom taskbar)
38+
./install.sh --tags developer,base,winlike
39+
40+
# Include macOS-style GNOME desktop (dock, logo menu, magic lamp)
41+
./install.sh --tags developer,base,maclike
42+
43+
# Exclude specific features (ghostty, fastestmirror, wallpaper)
44+
./install.sh --tags-exclude ghostty,wallpaper
45+
46+
# Dry-run to see what would change
47+
./install.sh --check
4348
```
4449

4550
The Ansible-based installer automatically detects your OS and installs the appropriate packages.
4651

47-
### Selective Installation (Advanced)
52+
### Tag-Based Installation
4853

49-
You can install specific components using Ansible tags. **Dependencies (init tasks) always run automatically.**
54+
All options use Ansible tags. Use `--tags` to include features, `--tags-exclude` to exclude them.
5055

51-
#### Using install.sh with tags:
5256
```bash
53-
# Install only Docker on macOS
54-
./install.sh --tags docker
55-
56-
# Install only Git and GitHub CLI
57-
./install.sh --tags git
57+
# Include specific tags
58+
./install.sh --tags developer,base,winlike
5859

59-
# Install Kubernetes tools only
60-
./install.sh --tags k8s
60+
# Exclude specific tags (from default or --all)
61+
./install.sh --tags-exclude ghostty,wallpaper
6162

62-
# Install multiple specific tools
63-
./install.sh --tags "docker,git,k8s"
63+
# Combine: install everything except specific features
64+
./install.sh --all --tags-exclude wallpaper
6465
```
6566

66-
#### Using Ansible directly:
67-
```bash
68-
cd ansible
67+
#### Available Tags
6968

70-
# Install only Docker (dependencies run automatically)
71-
ansible-playbook -i inventories/localhost/inventory.yml playbooks/main.yml --tags docker
69+
**Base Tags (included by default):**
7270

73-
# Install Git + Cloud tools
74-
ansible-playbook -i inventories/localhost/inventory.yml playbooks/main.yml --tags "git,cloud"
71+
- `developer` - Base DFE developer role
72+
- `base` - Base tools (Docker, Git, K8s, Python, VS Code, Chrome)
7573

76-
# Install everything EXCEPT Ghostty terminal
77-
ansible-playbook -i inventories/localhost/inventory.yml playbooks/main.yml --skip-tags ghostty
78-
```
74+
**Feature Tags (opt-in, require explicit --tags or --all):**
7975

80-
#### Available Tags
76+
- `winlike` - Windows-style GNOME taskbar (Dash to Panel, bottom panel)
77+
- `maclike` - macOS-style GNOME dock (Dash to Dock, Logo Menu, Magic Lamp)
78+
- `core` - Core developer tools (JFrog, Azure CLI, Node.js, Linear CLI)
79+
- `advanced` - Advanced tools (included with --core)
80+
- `vm` - VM guest optimizations (QEMU guest agent, SPICE agent)
81+
- `optimizer` - VM optimizer role (included with --vm)
82+
- `rdp` - GNOME Remote Desktop configuration (RDP server on port 3389)
83+
84+
**Optional Tags (included by default, can be excluded):**
85+
86+
- `ghostty` - Ghostty terminal emulator
87+
- `fastestmirror` - DNF/APT performance optimizations
88+
- `wallpaper` - Custom DFE wallpaper
89+
90+
**Component Tags:**
8191

82-
**Base Developer Tools:**
8392
- `docker` - Docker Desktop (macOS) or Docker CE (Linux)
8493
- `git` - Latest Git + GitHub CLI + Git LFS
8594
- `cloud` - AWS CLI, Helm, Terraform, Vault
@@ -88,9 +97,9 @@ ansible-playbook -i inventories/localhost/inventory.yml playbooks/main.yml --ski
8897
- `utilities` - Development utilities (jq, bat, fzf, ripgrep, etc.)
8998
- `vscode` - Visual Studio Code
9099
- `chrome` - Google Chrome
91-
- `ghostty` - Ghostty terminal emulator
92100

93-
**Core Developer Tools:**
101+
**Core Component Tags (require --core or explicit --tags):**
102+
94103
- `jfrog` - JFrog CLI
95104
- `azure` - Azure CLI
96105
- `nodejs` - Node.js + semantic-release
@@ -99,59 +108,21 @@ ansible-playbook -i inventories/localhost/inventory.yml playbooks/main.yml --ski
99108
- `claude` - Claude Code CLI
100109
- `slack` - Slack (GUI)
101110

102-
**System:**
103-
- `repository` - Configure package repositories (Linux only)
104-
- `security` - Automatic security updates
105-
- `wallpaper` - Custom wallpaper (if provided)
106-
- `verify` - Verify all installations
107-
108-
#### How It Works
109-
110-
**Dependencies always run:**
111-
- Init tasks (tagged `always`) run before any other tasks
112-
- Variables, user detection, platform detection
113-
- Ensures all prerequisites met
114-
115-
**Example: Install only Docker on macOS**
116-
```bash
117-
./install.sh --tags docker
118-
```
119-
120-
This will:
121-
1. ✅ Run init tasks (detect user, set variables)
122-
2. ✅ Install Docker Desktop via Homebrew
123-
3. ✅ Configure Docker
124-
4. ⏭️ Skip all other tools (Git, K8s, etc.)
111+
#### Using Ansible directly
125112

126-
**Example: Install multiple specific tools**
127113
```bash
128-
./install.sh --tags "git,docker,vscode"
129-
```
130-
131-
This installs only Git, Docker, and VS Code (plus their dependencies).
132-
133-
134-
## Fedora Linux (Legacy)
135-
136-
**Fedora-only shell scripts - bug fixes only, no new features.**
114+
cd ansible
137115

138-
```bash
139-
# Clone the repository
140-
git clone https://github.com/hypersec-io/dfe-developer
141-
cd dfe-developer/fedora
116+
# Install only Docker (dependencies run automatically)
117+
ansible-playbook -i inventories/localhost/inventory.yml playbooks/main.yml --tags docker
142118

143-
# Complete installation
144-
./install-all.sh 2>&1 | tee install.log
119+
# Install with winlike desktop
120+
ansible-playbook -i inventories/localhost/inventory.yml playbooks/main.yml --tags developer,base,winlike
145121

146-
# OR install components individually:
147-
./install-dfe-developer.sh # Base developer tools
148-
./install-dfe-developer-core.sh # Core DFE tools
149-
./install-vm-optimizer.sh # VM optimizations
150-
./install-rdp-optimizer.sh # RDP optimizations
122+
# Install everything EXCEPT Ghostty terminal
123+
ansible-playbook -i inventories/localhost/inventory.yml playbooks/main.yml --skip-tags ghostty
151124
```
152125

153-
**Note:** The `/fedora` scripts are maintained for bug fixes only. All new features and enhancements go into the Ansible playbooks. Use `./install.sh` (Ansible) for new installations.
154-
155126
## What Gets Installed
156127

157128
### Standard Developer Tools
@@ -173,32 +144,13 @@ cd dfe-developer/fedora
173144

174145
## System Requirements
175146

176-
### Multi-Platform (Ansible)
177147
- **Ubuntu:** 24.04 LTS or later (primary)
178-
- **Fedora:** 42 or later (secondary)
179-
- **macOS:** Sequoia 15.3.1 or later (secondary)
180-
- 4GB RAM minimum (8GB recommended)
181-
- 20GB available disk space
182-
- Internet connection
183-
184-
### Legacy Fedora (Shell Scripts)
185-
- Fedora 42 or later
148+
- **Fedora:** 42 or later
149+
- **macOS:** Sequoia 15.3.1 or later
186150
- 4GB RAM minimum (8GB recommended)
187151
- 20GB available disk space
188152
- Internet connection
189153

190-
## Testing
191-
192-
The project includes comprehensive testing:
193-
194-
```bash
195-
cd fedora/tests
196-
197-
# Run all tests
198-
bash 01-shellcheck.sh # Static analysis
199-
bats *.bats # Unit and integration tests
200-
```
201-
202154
## Project Structure
203155

204156
- `ansible/` - Ansible-based multi-platform installer (Fedora, Ubuntu, macOS)

ansible/roles/dfe_developer/defaults/main.yml

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,7 @@
11
---
22
# DFE Developer Environment - Defaults
3-
4-
# Mirror/repository optimization configuration
5-
dfe_use_fastestmirror: true # Enable fastest mirror selection (automatic mirror selection)
6-
# Note: Fedora uses fastestmirror, Ubuntu uses mirror selection in sources.list
7-
# Set to false with --no-fastestmirror flag to use default repos only
3+
# All options are now controlled via tags, not variables.
4+
# Use --skip-tags to disable features, --tags to enable optional ones.
85

96
# Supported platforms (used for validation in init.yml)
107
dfe_supported_distros:
@@ -14,13 +11,6 @@ dfe_supported_distros:
1411
dfe_min_fedora_version: 42
1512
dfe_min_ubuntu_version: "24.04"
1613

17-
# Ghostty installation
18-
dfe_install_ghostty: true
19-
20-
# GNOME Shell customizations (Dash to Panel, system monitor, dark theme, etc.)
21-
# Set to false to keep vanilla Ubuntu/Fedora GNOME experience
22-
dfe_customize_gnome_shell: true
23-
2414
# Docker configuration
2515
dfe_docker_users:
2616
- "{{ ansible_user_id }}"

ansible/roles/dfe_developer/files/dconf-dfe-defaults

Lines changed: 0 additions & 58 deletions
This file was deleted.
Lines changed: 65 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
# DFE Developer GNOME defaults - macOS-like style
2+
# Deployed to /etc/dconf/db/local.d/00-dfe-defaults
3+
# Run 'dconf update' after modifying
4+
5+
[org/gnome/shell]
6+
# Enable user extensions globally
7+
disable-user-extensions=false
8+
9+
# Extensions to enable by default
10+
# Dash to Dock + Logo Menu + Magic Lamp provide macOS-style experience
11+
enabled-extensions=['system-monitor@gnome-shell-extensions.gcampax.github.com', 'dash-to-dock@micxgx.gmail.com', 'logomenu@aryan_k', 'compiz-alike-magic-lamp-effect@hermes83.github.com']
12+
13+
# Extensions to disable by default
14+
# Ubuntu Dock conflicts with Dash to Dock
15+
disabled-extensions=['ubuntu-dock@ubuntu.com', 'workspace-indicator@gnome-shell-extensions.gcampax.github.com', 'apps-menu@gnome-shell-extensions.gcampax.github.com']
16+
17+
[org/gnome/shell/extensions/system-monitor]
18+
# System monitor configuration
19+
show-cpu=true
20+
show-memory=true
21+
show-download=false
22+
show-upload=false
23+
show-swap=false
24+
25+
[org/gnome/shell/extensions/dash-to-dock]
26+
# Dash to Dock - macOS-style dock configuration
27+
# Position at bottom like macOS
28+
dock-position='BOTTOM'
29+
# Intelligent auto-hide (like macOS)
30+
intellihide=true
31+
autohide=true
32+
# Click to minimize
33+
click-action='minimize'
34+
# Show running app indicators
35+
running-indicator-style='DOTS'
36+
# Show window previews on hover
37+
show-windows-preview=true
38+
# Icon size
39+
dash-max-icon-size=48
40+
# Hide trash and mounts from dock
41+
show-trash=false
42+
show-mounts=false
43+
44+
[org/gnome/shell/extensions/logo-menu]
45+
# Logo Menu - macOS-style Apple menu
46+
# Hide activities button (Logo Menu replaces it)
47+
show-activities-button=false
48+
49+
[org/gnome/shell/extensions/com.github.hermes83.compiz-alike-magic-lamp-effect]
50+
# Magic Lamp minimize effect - like macOS Genie
51+
duration=200
52+
53+
[org/gnome/desktop/wm/preferences]
54+
# Window buttons: minimize, maximize, close on right side
55+
button-layout=':minimize,maximize,close'
56+
57+
[org/gnome/desktop/interface]
58+
# Prefer dark theme
59+
color-scheme='prefer-dark'
60+
61+
[org/gnome/desktop/background]
62+
# DFE background image (stored in /usr/local, safe from apt/dnf updates)
63+
picture-uri='file:///usr/local/share/backgrounds/dfe-background.svg'
64+
picture-uri-dark='file:///usr/local/share/backgrounds/dfe-background.svg'
65+
picture-options='zoom'

0 commit comments

Comments
 (0)