-
Notifications
You must be signed in to change notification settings - Fork 0
/
homeserver.bu
203 lines (197 loc) · 5.67 KB
/
homeserver.bu
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
variant: fcos
version: 1.5.0
passwd:
users:
- name: core
uid: 1000
ssh_authorized_keys:
- ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAILHJZ+2vk9Rp1A6E9bTA2YwjPEpEe971rOncf6kNqlEB julius@thinkarch
- ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIH0dmrJbykJIRxFlTUsiMLrcR8FIAHuMdAd8Z8o2PV9u julius@bazzitetower
storage:
disks:
- device: /dev/disk/by-id/coreos-boot-disk
wipe_table: false
partitions:
- label: root
number: 4
size_mib: 16384
resize: true
- label: swap
size_mib: 16384
- label: var
size_mib: 0
filesystems:
- path: /var
device: /dev/disk/by-partlabel/var
format: xfs
with_mount_unit: true
- device: /dev/disk/by-partlabel/swap
format: swap
wipe_filesystem: true
with_mount_unit: true
links:
- path: /etc/localtime
target: ../usr/share/zoneinfo/Europe/Berlin
- path: /home/core/.config/systemd/user/timers.target.wants/podman-auto-update.timer
user:
name: core
group:
name: core
target: /usr/lib/systemd/user/podman-auto-update.timer
hard: false
files:
- path: /etc/hostname
mode: 0644
contents:
inline: homeserver
overwrite: true
- path: /etc/lvm/devices/system.devices
overwrite: true
mode: 0644
contents:
inline: |
# LVM uses devices listed in this file.
# Created by LVM command lvmdevices pid 3547 at Mon Apr 15 17:41:58 2024
PRODUCT_UUID=5d1e6aea-92bf-43ee-aafd-3c7bd73218ee
VERSION=1.1.8
IDTYPE=md_uuid IDNAME=6bfd352d-0e94-b84a-607f-91174b43ba8a DEVNAME=/dev/md127 PVID=Td7T7vbdeWeWQK9wI0P24WvGmUeRqSuH
IDTYPE=md_uuid IDNAME=6bcebd12-bd6c-4ab3-5d81-dd578999c7f6 DEVNAME=/dev/md126 PVID=ydlbIbnJeaaH8MyqXNdSBulyBySojAD9
IDTYPE=md_uuid IDNAME=09500011-d336-e01b-a8a1-3536484ab859 DEVNAME=/dev/md125 PVID=4e2Q1iB7CBTKz0qh2DXroLMpehHSiyqH
IDTYPE=sys_wwid IDNAME=naa.500a0751e59353bb DEVNAME=/dev/sdc1 PVID=nDS6wbKJRla0fF2NIs6R6tk9Sc01TQL6 PART=1
- path: /var/srv/proxy/Caddyfile
mode: 0644
contents:
local: config/Caddyfile
overwrite: true
user:
name: core
group:
name: core
- path: /var/srv/godns/config_ipv4.json
mode: 0644
contents:
local: config/config_ipv4.json
overwrite: true
user:
name: core
group:
name: core
- path: /var/srv/godns/config_ipv6.json
mode: 0644
contents:
local: config/config_ipv6.json
overwrite: true
user:
name: core
group:
name: core
- path: /var/lib/systemd/linger/core
mode: 0644
- path: /etc/systemd/system/user@.service.d/override.conf
mode: 0644
contents:
inline: |
# Systemd workaround to depend on network-online for user services
# https://github.com/systemd/systemd/issues/3312
[Unit]
After=network-online.target
Wants=network-online.target
- path: /etc/systemd/system/raid-check.timer.d/override.conf
mode: 0644
contents:
inline: |
[Timer]
OnCalendar=
OnCalendar=Sun *-*-* 8:00:00
- path: /etc/sysctl.d/90-net-unpriviliged.conf
mode: 0644
contents:
inline: |
net.ipv4.ip_unprivileged_port_start=80
directories:
- path: /var/srv/calibre
mode: 0700
- path: /var/srv/proxy
mode: 0700
- path: /var/srv/bitwarden
mode: 0700
- path: /var/srv/jackett
mode: 0700
- path: /var/srv/godns
mode: 0700
- path: /etc/systemd/system/user@.service.d
mode: 0755
- path: /etc/containers/systemd/users/1000
mode: 0755
- path: /etc/systemd/system/raid-check.timer.d
mode: 0755
- path: /home/core/.config
mode: 0755
user:
name: core
group:
name: core
- path: /home/core/.config/systemd
mode: 0755
user:
name: core
group:
name: core
- path: /home/core/.config/systemd/user
mode: 0755
user:
name: core
group:
name: core
- path: /home/core/.config/systemd/user/timers.target.wants
mode: 0755
user:
name: core
group:
name: core
trees:
- path: /etc/containers/systemd/users/1000
local: containers
- path: /etc/containers/systemd
local: containers-root
systemd:
units:
- name: podman-auto-update.timer
enabled: true
- name: vuetorrent.service
enabled: true
contents: |
[Unit]
Description=Pull vuetorrent and extract to /var/srv/vuetorrent
After=network-online.target
Wants=network-online.target
ConditionPathExists=!/var/srv/vuetorrent
[Service]
User=1000
Group=1000
Type=oneshot
RemainAfterExit=yes
WorkingDirectory=/var/srv
ExecStart=bash -c "curl https://github.com/VueTorrent/VueTorrent/releases/download/v2.7.3/vuetorrent.zip -L -o - | bsdtar -xf-"
[Install]
WantedBy=multi-user.target
- name: var-preciousvol.mount
enabled: true
contents: |
[Mount]
What=/dev/RaidPool/preciousvol
Where=/var/preciousvol
Type=xfs
[Install]
WantedBy=local-fs.target
- name: render-group.service
enabled: true
contents: |
[Unit]
ConditionFirstBoot=true
[Service]
Type=oneshot
RemainAfterExit=yes
ExecStart=bash -c 'grep ^render: /usr/lib/group >> /etc/group && usermod -G render -a core'
[Install]
WantedBy=multi-user.target default.target