rename: provider and stunnel templates to resources/templates/ (#143 stage 1) #182

Merged
mysticalsoap merged 1 commit from template-rename into trunk 2026-08-27 19:05:38 -04:00
Owner

Problem

resources/ mixes templates and configs under config-ish names (#143): the per-type OpenVPN base templates ship as Airvpn_config etc., and the stunnel template as ssl_config, next to actual defaults like firewall_default.json.

Fix

Stage 1 of #143 — the cheap rename:

  • resources/Airvpn_config (+ Mullvad/ProtonVPN/Windscribe) → resources/templates/{Type}.ovpn
  • resources/ssl_config → resources/templates/stunnel.conf
  • Installed location moves with them: /usr/share/aqomui/templates/
  • One code reference each updated: update.py copy_certs seed path, tunnel.py stunnel reads (×2), setup.py data_files, PKGBUILD install block (the resources/*_config glob is gone)
  • New drift guard next to the registry-pinning test: every SUPPORTED_PROVIDERS entry must ship a templates/{Type}.ovpn, so a future provider can't be added registry-only and fail at first import

Stage 2 (stripping the embedded per-install auth-user-pass/ca paths, injecting them at seed time) stays open on #143, gated on the multi-entry work — and the ProtonVPN template shouldn't be over-invested in before #33 settles.

The {provider}_config dict key in the gui's apply_edit is untouched on purpose: the service ignores it for supported providers (always writes {provider}/openvpn.conf), so it's a D-Bus dict key, not a filename.

Verification

  • ruff check --select E9,F63,F7,F82 . clean; 435 tests pass (434 + the new template guard)
  • Repo-wide sweep for the five old filenames finds no remaining references (code, packaging, docs)
  • Live check to do before merge: packaging/arch/build-branch-and-install.sh, then a provider re-import (copy_certs seeds openvpn.conf from the new path) — the stunnel path only fires on Airvpn/Windscribe SSL connections

🤖 Generated with Claude Code

## Problem resources/ mixes templates and configs under config-ish names (#143): the per-type OpenVPN base templates ship as `Airvpn_config` etc., and the stunnel template as `ssl_config`, next to actual defaults like `firewall_default.json`. ## Fix Stage 1 of #143 — the cheap rename: - `resources/Airvpn_config` (+ Mullvad/ProtonVPN/Windscribe) → `resources/templates/{Type}.ovpn` - `resources/ssl_config` → `resources/templates/stunnel.conf` - Installed location moves with them: `/usr/share/aqomui/templates/` - One code reference each updated: `update.py` copy_certs seed path, `tunnel.py` stunnel reads (×2), `setup.py` data_files, PKGBUILD install block (the `resources/*_config` glob is gone) - New drift guard next to the registry-pinning test: every `SUPPORTED_PROVIDERS` entry must ship a `templates/{Type}.ovpn`, so a future provider can't be added registry-only and fail at first import Stage 2 (stripping the embedded per-install `auth-user-pass`/`ca` paths, injecting them at seed time) stays open on #143, gated on the multi-entry work — and the ProtonVPN template shouldn't be over-invested in before #33 settles. The `{provider}_config` dict key in the gui's apply_edit is untouched on purpose: the service ignores it for supported providers (always writes `{provider}/openvpn.conf`), so it's a D-Bus dict key, not a filename. ## Verification - `ruff check --select E9,F63,F7,F82 .` clean; 435 tests pass (434 + the new template guard) - Repo-wide sweep for the five old filenames finds no remaining references (code, packaging, docs) - Live check to do before merge: `packaging/arch/build-branch-and-install.sh`, then a provider re-import (copy_certs seeds openvpn.conf from the new path) — the stunnel path only fires on Airvpn/Windscribe SSL connections 🤖 Generated with [Claude Code](https://claude.com/claude-code)
rename: provider and stunnel templates to resources/templates/
All checks were successful
ci / test (pull_request) Successful in 26s
ci / test (push) Successful in 30s
8829e9c1c6
Airvpn_config and friends read as configs but are per-type OpenVPN base
templates (blank proto/remote filled in by write_config, seeded once
into {entry}/openvpn.conf by copy_certs), and ssl_config is the stunnel
template tunnel.py rewrites per connection. Name them what they are and
give them their own directory; actual defaults (firewall_default.json)
stay in the resources/ root. Installed location moves with them:
/usr/share/aqomui/templates/.

Stage 1 of #143 -- stripping the embedded per-install paths out of the
templates waits for the multi-entry work.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
mysticalsoap deleted branch template-rename 2026-08-27 19:05:38 -04:00
Sign in to join this conversation.
No description provided.