TELEICU/Path A: Ansible Pull: Difference between revisions
From OHC Network Wiki
More languages
More actions
Content deleted Content added
Create TELEICU Path A: Ansible Pull guide (via create-page on MediaWiki MCP Server) |
Fix Mermaid diagrams: remove <pre> wrapping so parser functions execute (via update-page on MediaWiki MCP Server) |
||
| (2 intermediate revisions by the same user not shown) | |||
| Line 12: | Line 12: | ||
All node configuration is declared in a central git repository. Each hospital PC runs <code>ansible-pull</code> on a cron or systemd timer, checking out the repo and applying the playbook for its host group. |
All node configuration is declared in a central git repository. Each hospital PC runs <code>ansible-pull</code> on a cron or systemd timer, checking out the repo and applying the playbook for its host group. |
||
{{#mermaid:flowchart LR |
|||
syntaxhighlight lang="text" |
|||
REPO["Git Repository<br/>(central playbooks)"] |
|||
┌──────────────────────┐ |
|||
CP["CP Node(s)<br/>(ansible-pull)"] |
|||
│ Git repository │ |
|||
SPOKE["Spoke Agent Node<br/>ansible-pull<br/>→ K3s agent<br/>→ middleware"] |
|||
│ (central playbooks) │ |
|||
HUB["Hub Agent Node<br/>ansible-pull<br/>→ K3s agent<br/>→ middleware"] |
|||
└──────────┬───────────┘ |
|||
REPO -->|"pull (HTTPS / Tailscale)"| CP |
|||
▼ |
|||
| ⚫ | |||
┌──────────────────────┐ |
|||
REPO -->|"per-agent pull"| HUB |
|||
│ CP node(s) │ |
|||
}} |
|||
│ (ansible-pull │ |
|||
│ also runs here) │ |
|||
└──────────┬───────────┘ |
|||
│ |
|||
| ⚫ | |||
┌──────────────────────┐ ┌──────────────────────┐ |
|||
│ Spoke agent node │ │ Hub agent node │ |
|||
│ ansible-pull │ │ ansible-pull │ |
|||
│ → K3s agent │ │ → K3s agent │ |
|||
│ → middleware │ │ → middleware │ |
|||
└──────────────────────┘ └──────────────────────┘ |
|||
syntaxhighlight |
|||
== What Ansible manages == |
== What Ansible manages == |
||
| Line 69: | Line 58: | ||
== Repository structure == |
== Repository structure == |
||
{{#mermaid:flowchart LR |
|||
syntaxhighlight lang="text" |
|||
ansible-teleicu/ |
subgraph Repo["ansible-teleicu/"] |
||
ROOT["site.yml<br/>ansible.cfg"] |
|||
├── site.yml # master playbook |
|||
INV["inventories/<br/>production/<br/>staging/"] |
|||
├── ansible.cfg |
|||
ROLES["roles/<br/>common/<br/>tailscale/<br/>k3s-agent/<br/>cloudflared/<br/>monitoring-agent/<br/>middleware/<br/>security-patches/"] |
|||
├── requirements.yml |
|||
VARS["group_vars/<br/>all.yml<br/>spokes.yml<br/>hubs.yml"] |
|||
├── inventories/ |
|||
VAULT["vault/"] |
|||
│ ├── production/ |
|||
end |
|||
│ │ ├── hosts.ini # grouped by state, role |
|||
}} |
|||
│ │ └── group_vars/ |
|||
│ └── staging/ |
|||
{{Navbox TELEICU}} |
|||
├── roles/ |
|||
│ ├── common/ # base hardening |
|||
│ ├── tailscale/ # tailscale install & bringup |
|||
│ ├── k3s-agent/ # join cluster |
|||
│ ├── cloudflared/ # tunnel service |
|||
│ ├── monitoring-agent/ # vmagent + downtime classifier |
|||
│ ├── middleware/ # docker compose or k3s manifest apply |
|||
│ └── security-patches/ # unattended-upgrades / apt pinning |
|||
├── group_vars/ |
|||
│ ├── all.yml |
|||
│ ├── spokes.yml |
|||
│ └── hubs.yml |
|||
└── vault/ # encrypted secrets |
|||
syntaxhighlight |
|||
{{Related}} |
{{Related}} |
||