Signed-off-by: Tuan-Dat Tran <tuan-dat.tran@tudattr.dev>
This commit is contained in:
Tuan-Dat Tran
2025-06-07 01:19:27 +02:00
parent 02168225b1
commit cb8ccd8f00
6 changed files with 40 additions and 79 deletions

View File

@@ -7,32 +7,6 @@ docker:
compose: "/opt/docker/compose/"
services:
- name: syncthing
vm:
- docker-host11
container_name: syncthing
image: syncthing/syncthing:1.29
volumes:
- name: "Data"
internal: /var/syncthing/
external: /media/docker/data/syncthing/
ports:
- name: "http"
internal: 8384
external: "{{ services_external_http.syncthing }}"
- name: ""
internal: 22000
external: 22000
- name: ""
internal: 22000
external: 22000
- name: ""
internal: 21027
external: 21027
environment:
- PUID=1000
- PGID=1000
- TZ=Europe/Berlin
- name: status
vm:
- docker-host12
@@ -52,7 +26,7 @@ services:
- TZ=Europe/Berlin
- name: plex
vm:
- docker-host11
- docker-host10
container_name: plex
image: lscr.io/linuxserver/plex:1.41.5
volumes:
@@ -435,7 +409,7 @@ services:
- name: cadvisor
vm:
- docker-host12
- docker-host11
- docker-host10
- docker-host01
container_name: cadvisor
image: gcr.io/cadvisor/cadvisor:v0.52.1

View File

@@ -1,5 +1,4 @@
services_external_http:
syncthing: 8384
kuma: 3001
plex: 32400
jellyfin: 8096

View File

@@ -1,20 +1,20 @@
$ANSIBLE_VAULT;1.1;AES256
34363461373039313430373835363633343139303333353934393762383338396664616636653331
6534613666613761663665323033383838663363376561620a636533303235393139653161643130
66316231383734343837656364643533633863613761633262653264663565303361323730613937
3935386538643939660a386134643831386261323363326439663263376439353966346632333366
33653736343263663961333033336563656265303166383032326338343038653961383862363339
35343362306237656130653039366464643565663439636432316362316238613730313366303964
30666536373634613236353634363333316534626234386666633861663065343063666236386631
36366238353635333339643163336166353262386234376435313136643937663961373663303565
34306637656537666231373931363963646238343664323633306361336661303830396465663231
33663531613437333730653765666361623462666237396531313833336461373439373264613266
62633132343036386131646539386266313162653263663137303866363432626135383865343565
66393838663038353263633437653563346331356539333563396465663664623065623735626630
35333630623830623530663266343235643136623735643335373932303262323761626537643266
36383132303366633238356161616539343335656665356430656236633031383938616263633866
39306461626363336162396634616133306566353835343035356338616636346538303933626365
62363035613931353837313762383230313337326639616263393965386639666164666531343064
66653536626439366430356266393761646135646534616139633733663830643534333832663764
34623837323864613935626639613961343965323664326661336135653634346239346261343935
616232353632663332373138313962616433
35616266333838306161336339353538306634373132626132643732303066303163343630333630
6338393762616262303038373334663230383464643836370a656538393531393134616463643239
36383330653339393362353838313639333432643535643833396535653632376336613130646663
3532646538363137630a363731613235653935316531616430346264643837306434386333373033
33663135653931373963343734366562386263663939383536663439383537333264666233343233
62626162666538333435396638393338393734656131303065616534613733353335643939333765
38326237343337363064666530303664326563633262313432343030336266373437353837346461
63333363626164316638346635666537613963383537313965373638303732353365623166363736
31633239646262613539646637663664313337353465636366313338303439613638653530656631
62396536316561623736633631623336313537646138383431633538303163303261323864383538
38626338373332653561343036323236383337343037356366626230646432646538373836303063
61346339376561626630653562346439306561643664666437386562356535303264646338326261
33636536663161366635666264663539653037306339316233643662643134396636636162656333
36666139376263646130333263653335333165356462363434373439313330383331356138333431
31633362343639376436616339656561316433346532346533336261383433366366396261366134
35363264373335616165643665653466613434386630373232386261393464376361313131386462
33333531336334386562356338623233313862316232356562373561633364363263306465333439
37386631626538636365376464653837333662363361653237366161316431653266643238346336
363863376530613036313866323965326638

View File

@@ -1,6 +1,6 @@
vms:
- name: "docker-host10"
node: "inko"
node: "lulu"
vmid: 410
cores: 2
memory: 4096 # in MiB
@@ -10,6 +10,8 @@ vms:
ciuser: "{{ user }}"
sshkeys: "{{ pubkey }}"
disk_size: 128 # in Gb
hostpci:
hostpci0: "0000:00:02.0"
- name: "docker-host11"
node: "lulu"
vmid: 411
@@ -21,24 +23,11 @@ vms:
ciuser: "{{ user }}"
sshkeys: "{{ pubkey }}"
disk_size: 128 # in Gb
- name: "docker-host13"
node: "lulu"
vmid: 413
cores: 2
memory: 4096 # in MiB
net:
net0: "virtio,bridge=vmbr0,firewall=1"
boot_image: "{{ proxmox_cloud_init_images.debian.name }}"
ciuser: "{{ user }}"
sshkeys: "{{ pubkey }}"
disk_size: 128 # in Gb
hostpci:
hostpci0: "0000:00:02.0"
- name: "docker-host12"
node: "naruto01"
vmid: 412
cores: 2
memory: 4096
cores: 4
memory: 8192
net:
net0: "virtio,bridge=vmbr0,firewall=1"
boot_image: "{{ proxmox_cloud_init_images.ubuntu.name }}"

View File

@@ -31,9 +31,10 @@ k3s-agent[00:02]
k3s-longhorn[00:02]
[docker]
# docker-host[00:01]
docker-host14
# docker-lb
docker-host01
docker-host10
docker-host12
docker-lb
[vps]
mii
@@ -54,8 +55,9 @@ k3s-postgres
k3s-loadbalancer
[docker_host]
# docker-host[00:01]
docker-host14
docker-host01
docker-host10
docker-host12
[docker_lb]
docker-lb

View File

@@ -12,14 +12,6 @@
when: debian_sources_stat.stat.exists
become: true
- name: "Wait for apt/dpkg locks to be released"
ansible.builtin.wait_for:
path: "{{ item }}"
state: absent
timeout: 300
delay: 5
loop: "{{ apt_lock_files }}"
- name: Setup VM Packages
ansible.builtin.apt:
name: "{{ item }}"
@@ -48,6 +40,11 @@
state: absent
autoremove: true
when: cloud_kernel_packages | length > 0
notify:
- Restart host
become: true
- name: Restart host
ansible.builtin.reboot:
connect_timeout: 5
reboot_timeout: 600
test_command: whoami
become: true