aboutsummaryrefslogtreecommitdiff
path: root/personal_infra/puppet/modules/proxmox/manifests/init.pp
blob: bd0fb812a84c0efd5543b02d5f6ce0e36eacbb8b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
class proxmox {
  file {'/etc/network/interfaces':
    content => epp('proxmox/interfaces', {
      "network" => lookup("network"),
    }),
  }
  ~>
  exec {'/usr/sbin/ifreload -a':
    refreshonly => true
  }

  # to prevent Germany/Hetzner abuse complaints
  service {['rpcbind.target', 'rpcbind.service', 'rpcbind.socket']:
    ensure => stopped,
    enable => mask,
  }

  # TODO: secure this. Right now I don't use VMs, so just disable it
  service {'spiceproxy':
    ensure => stopped,
    enable => mask,
  }

  file {'/etc/logrotate.d/pve':
    ensure => absent,
  }
  ~>
  service {'logrotate':}

  file {'/etc/apt/sources.list.d/pve-enterprise.list':
    ensure => absent,
  }

  file {'/etc/apt/sources.list.d/pve-no-subscription.list':
    content => 'deb http://download.proxmox.com/debian/pve bookworm pve-no-subscription
',
  }
}