diff options
| author | Xe Iaso <me@xeiaso.net> | 2024-08-19 10:03:43 -0400 |
|---|---|---|
| committer | Xe Iaso <me@xeiaso.net> | 2024-08-19 10:04:11 -0400 |
| commit | f0cc46bcfd503e775e0a5f428ce5439f634e3ba0 (patch) | |
| tree | 2ae747fa16a28499e69bb9cc41822d076378bf05 | |
| parent | 65dc9f57bd43ea1d30b7967f72d81811b4a1c521 (diff) | |
| download | x-f0cc46bcfd503e775e0a5f428ce5439f634e3ba0.tar.xz x-f0cc46bcfd503e775e0a5f428ce5439f634e3ba0.zip | |
commit arona config
Signed-off-by: Xe Iaso <me@xeiaso.net>
| -rw-r--r-- | kube/alrest/vms/arona/arona.yaml | 103 | ||||
| -rw-r--r-- | kube/alrest/vms/arona/bashrc.append | 1 | ||||
| -rw-r--r-- | kube/alrest/vms/arona/weechat.service | 12 |
3 files changed, 116 insertions, 0 deletions
diff --git a/kube/alrest/vms/arona/arona.yaml b/kube/alrest/vms/arona/arona.yaml new file mode 100644 index 0000000..570ccab --- /dev/null +++ b/kube/alrest/vms/arona/arona.yaml @@ -0,0 +1,103 @@ +apiVersion: cdi.kubevirt.io/v1beta1 +kind: DataVolume +metadata: + name: "arona" + namespace: waifud +spec: + storage: + storageClassName: longhorn + volumeMode: Block # or filesystem + accessModes: + - ReadWriteOnce # Necessary as it's no longer has a default + resources: + requests: + storage: 64Gi + source: + http: + url: "https://cloud-images.ubuntu.com/daily/server/noble/current/noble-server-cloudimg-amd64.img" +--- +apiVersion: v1 +kind: Service +metadata: + name: arona + namespace: waifud +spec: + ports: + # ssh + - port: 22 + protocol: TCP + targetPort: 22 + name: ssh + # IRC relay + - port: 12482 + protocol: TCP + targetPort: 12482 + name: irc-relay + # Weechat relay + - port: 28945 + protocol: TCP + targetPort: 28945 + name: weechat-relay + selector: + kubevirt.io/domain: "arona" + type: ClusterIP +--- +apiVersion: kubevirt.io/v1 +kind: VirtualMachine +metadata: + labels: + kubevirt.io/os: linux + name: "arona" + namespace: waifud +spec: + running: true + template: + metadata: + creationTimestamp: null + labels: + kubevirt.io/domain: "arona" + spec: + domain: + cpu: + cores: 1 + devices: + disks: + - disk: + bus: virtio + name: disk0 + - cdrom: + bus: sata + readonly: true + name: cloudinitdisk + machine: + type: q35 + resources: + requests: + memory: 4096M + volumes: + - name: disk0 + persistentVolumeClaim: + claimName: "arona" + - cloudInitNoCloud: + userData: | + #cloud-config + hostname: arona + ssh_pwauth: True + disable_root: false + + users: + - name: xe + groups: [ wheel ] + sudo: [ "ALL=(ALL) NOPASSWD:ALL" ] + shell: /bin/bash + ssh-authorized-keys: + - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIF6/+q2dBHEfETomAH7rvDPXHulSXnhcV/szxTAWiKZA cadey@defoko + - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJIH27tCTJZwJxp+bcWRALtrk7SqnwXZ4/Ae67jIO0eF cadey@shiroko + - name: root + groups: [ wheel ] + sudo: [ "ALL=(ALL) NOPASSWD:ALL" ] + shell: /bin/bash + ssh-authorized-keys: + - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIF6/+q2dBHEfETomAH7rvDPXHulSXnhcV/szxTAWiKZA cadey@defoko + - ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJIH27tCTJZwJxp+bcWRALtrk7SqnwXZ4/Ae67jIO0eF cadey@shiroko + name: cloudinitdisk
\ No newline at end of file diff --git a/kube/alrest/vms/arona/bashrc.append b/kube/alrest/vms/arona/bashrc.append new file mode 100644 index 0000000..f02ed2f --- /dev/null +++ b/kube/alrest/vms/arona/bashrc.append @@ -0,0 +1 @@ +alias chats='tmux -L weechat attach'
\ No newline at end of file diff --git a/kube/alrest/vms/arona/weechat.service b/kube/alrest/vms/arona/weechat.service new file mode 100644 index 0000000..d2ece5f --- /dev/null +++ b/kube/alrest/vms/arona/weechat.service @@ -0,0 +1,12 @@ +[Unit] +Description=A WeeChat client and relay service using Tmux +After=network.target + +[Service] +Type=forking +RemainAfterExit=yes +ExecStart=/usr/bin/tmux -L weechat new -d -s weechat weechat +ExecStop=/usr/bin/tmux -L weechat kill-session -t weechat + +[Install] +WantedBy=default.target
\ No newline at end of file |
