feat: add samba and proxmox modules, update config with node secrets

This commit is contained in:
Fredrick Amnehagen 2026-02-05 17:13:40 +01:00
parent a80be5d8aa
commit 9c8c771cb1
7 changed files with 203 additions and 6 deletions

View file

@ -2,10 +2,15 @@ from .ssh import SSHClient
class DNSManager:
def __init__(self, config):
self.pve_host = config.get('proxmox.host')
# DNS is on la-vmh-11 (dnsmasq_lxc_id)
node = config.get_node('la-vmh-11')
if not node:
raise ValueError("Node 'la-vmh-11' not found in config")
self.pve_host = node['host']
self.pve_user = config.get('proxmox.user', 'root')
self.lxc_id = config.get('proxmox.dnsmasq_lxc_id')
self.ssh_key = config.get('proxmox.ssh_key')
self.ssh_key = config.get('proxmox.ssh_key_path')
self.client = SSHClient(self.pve_host, self.pve_user, self.ssh_key)
self.hosts_file = "/etc/dnsmasq.d/dynamic-hosts.conf"