Compare commits
19 Commits
6fe25801c1
...
7f5edfcd37
Author | SHA1 | Date |
---|---|---|
|
7f5edfcd37 | |
|
7da76d0615 | |
|
f9a315eba5 | |
|
cf8dff83eb | |
|
3abecae4d8 | |
|
3255edc7b6 | |
|
bed5ed5767 | |
|
4d11a60e62 | |
|
edec79aaae | |
|
28e120ddbd | |
|
58d2f94842 | |
|
983bf4808d | |
|
ffdcf6bd73 | |
|
6bee9847fc | |
|
0e1eefc13f | |
|
4c0efc6a87 | |
|
d16f27394c | |
|
dc835ddc9d | |
|
f637feba16 |
|
@ -1 +1,2 @@
|
|||
ara/.secrets.toml
|
||||
host-provisioner.key
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAICoOO/ZYMxRgmyvqZwGN3NM5pHyh3NBdC7iZrXIopt93 Host Provisioner
|
|
@ -13,6 +13,8 @@ namespace: ansible
|
|||
|
||||
resources:
|
||||
- ../dch-root-ca
|
||||
- ../ssh-host-keys
|
||||
- rbac.yaml
|
||||
- secrets.yaml
|
||||
- namespace.yaml
|
||||
- ara.yaml
|
||||
|
|
|
@ -0,0 +1,25 @@
|
|||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
kind: Role
|
||||
metadata:
|
||||
name: dch-webhooks
|
||||
rules:
|
||||
- apiGroups:
|
||||
- batch
|
||||
resources:
|
||||
- jobs
|
||||
verbs:
|
||||
- create
|
||||
|
||||
---
|
||||
apiVersion: rbac.authorization.k8s.io/v1
|
||||
kind: RoleBinding
|
||||
metadata:
|
||||
name: dch-webhooks
|
||||
roleRef:
|
||||
apiGroup: rbac.authorization.k8s.io
|
||||
kind: Role
|
||||
name: dch-webhooks
|
||||
subjects:
|
||||
- kind: ServiceAccount
|
||||
name: dch-webhooks
|
||||
namespace: default
|
|
@ -17,3 +17,21 @@ spec:
|
|||
labels:
|
||||
app.kubernetes.io/name: ara
|
||||
app.kubernetes.io/component: ara
|
||||
|
||||
---
|
||||
apiVersion: bitnami.com/v1alpha1
|
||||
kind: SealedSecret
|
||||
metadata:
|
||||
name: provisioner-ssh-key
|
||||
namespace: ansible
|
||||
labels: &labels
|
||||
app.kubernetes.io/name: provisioner-ssh-key
|
||||
app.kubernetes.io/component: host-provisioner
|
||||
spec:
|
||||
encryptedData:
|
||||
host-provisioner.key: AgCiBQEtPmzQO9GHoVxZNQmjFn9GjeKWlHmG2lz4uqeva77QByqnejUg8CbpQnoT61ct9o39tVtrrHgC8WjseXKGKkd+YELRaWENXBNBFlv4YN6id2iPzf4xHrgfowXLjzly7s4s4Fg3QntXFglQxwG009Z7K5HQmAvgCFzGm6y+fyLoNd2v2eNc9pGurynnm7wKQFuBBpBtoDVfYMNSS+tp9D3MFVMwEG8kU/kszv5OEEwVkipG4v2LeY86HXIQnHyeE3vITz0TFPoQjpjusBNg7MxBVHcz/ZruqF43DZ+uz2aRFL6D5udm86hsxZGSi3yVq8PSCUANtWoTicIpSc5yxpB+5FLsc3Q380vQPrRYvx8luAZwMGQPDv2NpGoSRUmutb/+4vpQbCBwaP9s8WHaYNDByUeoQKAX2o+RYp+/csfxmSy1/pK93RUjMnsWGYiyI7jpNdTqWkakDN+cM0Lrje9+VqcZge3FYp/4y78AI75pWEiEMy1VSXeqE2pgu5vZzyRdw9zORC2sAWhnTeu+Obbly1UdptpXPmGclmRbpwAPM1F7m7pDsCQ9SYAhoGg251Yu0sF3Nnc0uOElmP0KSn1bt/Jca9M0syg9DMntHo41dn40+Aihujej0ll4h3GXVZ0auUuzSLZEMe0dHQY0YCaq3JdeOa6AJuNyo63/0BmvmWP2T06INtVw4EqBsmvNl/YJIlZiRGhIOGaRyJllu21L6QBtToYjxI7fhTxZaCG6fyPbvCd1hu+IchoMr86rl7W0+k6d/lkamx9dg+PtWjjThOGyeLYwSRhMcsvQPsSdTl8BEmB9TRgRIk42txVRQkb+ei1+1y9nBYCOV9P540lDXQVbqgyb0j2cccWOa/AG7l3P3s8haDs2OujUaVkBJWJ489nsLsC33972wwAQbOk+uTKmXKL6nWSNL31rivW9R8ea+vfdcyN2/tLsI0mE9XTR/kRmS12qdLmDbzeX/scqSKaWFQZwnLHak5Xaqkd25ZGHqB3zrnTBIryDaXSzgC1CPCv7QNqbKvd6vmH+16j1DWqLycbUeorx5O9nwpEZ+GzQm8q62PJEO8xdvqr3nu5OvFgGrnX/Y6giV8Cv8ogyAxbmNrq0cC5VYxDlt4VvzlOpmWUlfxD/wd+gaHQoibhhHRbGtsJCX9AFclVQrY3kmduTi/iJlTTJjMQKm9JJRXKbNDxH+B25Zj/hUIC1/NNZOSDn654Pi/yOGXITp86j9unfnIXdJPg=
|
||||
template:
|
||||
metadata:
|
||||
name: provisioner-ssh-key
|
||||
namespace: ansible
|
||||
labels: *labels
|
||||
|
|
|
@ -2,7 +2,7 @@ apiVersion: kustomize.config.k8s.io/v1beta1
|
|||
kind: Kustomization
|
||||
|
||||
resources:
|
||||
- https://github.com/cert-manager/cert-manager/releases/download/v1.14.5/cert-manager.yaml
|
||||
- https://github.com/cert-manager/cert-manager/releases/download/v1.16.4/cert-manager.yaml
|
||||
- cluster-issuer.yaml
|
||||
- certificates.yaml
|
||||
- cert-exporter.yaml
|
||||
|
|
|
@ -5,3 +5,5 @@ configMapGenerator:
|
|||
- name: dch-root-ca
|
||||
files:
|
||||
- dch-root-ca.crt
|
||||
options:
|
||||
disableNameSuffixHash: true
|
||||
|
|
|
@ -0,0 +1,115 @@
|
|||
apiVersion: batch/v1
|
||||
kind: Job
|
||||
metadata:
|
||||
generateName: host-provision-
|
||||
labels: &labels
|
||||
app.kubernetes.io/name: host-provisioner
|
||||
app.kubernetes.io/component: host-provisioner
|
||||
spec:
|
||||
backoffLimit: 0
|
||||
template:
|
||||
metadata:
|
||||
labels: *labels
|
||||
spec:
|
||||
restartPolicy: Never
|
||||
initContainers:
|
||||
- name: ssh-agent
|
||||
image: &image git.pyrocufflink.net/infra/host-provisioner
|
||||
imagePullPolicy: Always
|
||||
command:
|
||||
- tini
|
||||
- ssh-agent
|
||||
- --
|
||||
- -D
|
||||
- -a
|
||||
- /run/ssh/agent.sock
|
||||
restartPolicy: Always
|
||||
securityContext:
|
||||
readOnlyRootFilesystem: true
|
||||
volumeMounts:
|
||||
- mountPath: /run/ssh
|
||||
name: tmp
|
||||
subPath: run/ssh
|
||||
- name: ssh-add
|
||||
image: *image
|
||||
command:
|
||||
- ssh-add
|
||||
- -t
|
||||
- 30m
|
||||
- /run/secrets/ssh/host-provisioner.key
|
||||
env:
|
||||
- name: SSH_AUTH_SOCK
|
||||
value: /run/ssh/agent.sock
|
||||
securityContext:
|
||||
readOnlyRootFilesystem: true
|
||||
volumeMounts:
|
||||
- mountPath: /run/ssh
|
||||
name: tmp
|
||||
subPath: run/ssh
|
||||
- mountPath: /run/secrets/ssh
|
||||
name: provisioner-key
|
||||
readOnly: true
|
||||
containers:
|
||||
- name: host-provisioner
|
||||
image: *image
|
||||
env:
|
||||
- name: SSH_AUTH_SOCK
|
||||
value: /run/ssh/agent.sock
|
||||
- name: AMQP_HOST
|
||||
value: rabbitmq.pyrocufflink.blue
|
||||
- name: AMQP_PORT
|
||||
value: '5671'
|
||||
- name: AMQP_CA_CERT
|
||||
value: /run/dch-ca/dch-root-ca.crt
|
||||
- name: AMQP_CLIENT_CERT
|
||||
value: /run/secrets/host-provisioner/rabbitmq/tls.crt
|
||||
- name: AMQP_CLIENT_KEY
|
||||
value: /run/secrets/host-provisioner/rabbitmq/tls.key
|
||||
- name: AMQP_EXTERNAL_CREDENTIALS
|
||||
value: '1'
|
||||
securityContext:
|
||||
readOnlyRootFilesystem: true
|
||||
volumeMounts:
|
||||
- mountPath: /etc/ssh/ssh_known_hosts
|
||||
name: ssh-known-hosts
|
||||
subPath: ssh_known_hosts
|
||||
readOnly: true
|
||||
- mountPath: /home/jenkins
|
||||
name: workspace
|
||||
- mountPath: /run/dch-ca
|
||||
name: dch-root-ca
|
||||
readOnly: true
|
||||
- mountPath: /run/ssh
|
||||
name: tmp
|
||||
subPath: run/ssh
|
||||
- mountPath: /run/secrets/host-provisioner/rabbitmq
|
||||
name: rabbitmq-cert
|
||||
readOnly: true
|
||||
- mountPath: /tmp
|
||||
name: tmp
|
||||
subPath: tmp
|
||||
securityContext:
|
||||
runAsNonRoot: true
|
||||
runAsUser: 1000
|
||||
runAsGroup: 1000
|
||||
fsGroup: 1000
|
||||
volumes:
|
||||
- name: dch-root-ca
|
||||
configMap:
|
||||
name: dch-root-ca
|
||||
- name: provisioner-key
|
||||
secret:
|
||||
secretName: provisioner-ssh-key
|
||||
defaultMode: 0440
|
||||
- name: ssh-known-hosts
|
||||
configMap:
|
||||
name: ssh-known-hosts
|
||||
- name: rabbitmq-cert
|
||||
secret:
|
||||
secretName: rabbitmq-cert
|
||||
defaultMode: 0440
|
||||
- name: tmp
|
||||
emptyDir:
|
||||
medium: Memory
|
||||
- name: workspace
|
||||
emptyDir: {}
|
|
@ -0,0 +1,14 @@
|
|||
apiVersion: cert-manager.io/v1
|
||||
kind: Certificate
|
||||
metadata:
|
||||
name: rabbitmq
|
||||
spec:
|
||||
secretName: rabbitmq-cert
|
||||
commonName: dch-webhooks
|
||||
issuerRef:
|
||||
group: cert-manager.io
|
||||
kind: ClusterIssuer
|
||||
name: rabbitmq-ca
|
||||
privateKey:
|
||||
algorithm: ECDSA
|
||||
rotationPolicy: Always
|
|
@ -7,3 +7,10 @@ STEP_CA_URL=https://ca.pyrocufflink.blue:32599
|
|||
STEP_ROOT=/run/dch-root-ca.crt
|
||||
STEP_PROVISIONER=host-bootstrap
|
||||
STEP_PROVISIONER_PASSWORD_FILE=/run/secrets/du5t1n.me/step-ca/provisioner.password
|
||||
|
||||
AMQP_HOST=rabbitmq.pyrocufflink.blue
|
||||
AMQP_PORT=5671
|
||||
AMQP_EXTERNAL_CREDENTIALS=1
|
||||
AMQP_CA_CERT=/run/dch-root-ca.crt
|
||||
AMQP_CLIENT_CERT=/run/secrets/du5t1n.me/rabbitmq/tls.crt
|
||||
AMQP_CLIENT_KEY=/run/secrets/du5t1n.me/rabbitmq/tls.key
|
||||
|
|
|
@ -1,4 +1,14 @@
|
|||
apiVersion: v1
|
||||
kind: ServiceAccount
|
||||
metadata:
|
||||
name: dch-webhooks
|
||||
labels:
|
||||
app.kubernetes.io/name: dch-webhooks
|
||||
app.kubernetes.io/component: dch-webhooks
|
||||
app.kubernetes.io/part-of: dch-webhooks
|
||||
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
labels:
|
||||
|
@ -42,12 +52,14 @@ spec:
|
|||
spec:
|
||||
containers:
|
||||
- name: dch-webhooks
|
||||
image: git.pyrocufflink.net/containerimages/dch-webhooks
|
||||
image: git.pyrocufflink.net/infra/dch-webhooks
|
||||
env:
|
||||
- name: UVICORN_HOST
|
||||
value: 0.0.0.0
|
||||
- name: UVICORN_LOG_LEVEL
|
||||
value: debug
|
||||
- name: ANSIBLE_JOB_YAML
|
||||
value: /etc/dch-webhooks/ansible-job.yaml
|
||||
envFrom:
|
||||
- configMapRef:
|
||||
name: dch-webhooks
|
||||
|
@ -76,22 +88,37 @@ spec:
|
|||
name: firefly-token
|
||||
- mountPath: /run/secrets/du5t1n.me/paperless
|
||||
name: paperless-token
|
||||
- mountPath: /run/secrets/du5t1n.me/rabbitmq
|
||||
name: rabbitmq-cert
|
||||
readOnly: true
|
||||
- mountPath: /run/secrets/du5t1n.me/step-ca
|
||||
name: step-ca-password
|
||||
- mountPath: /tmp
|
||||
name: tmp
|
||||
subPath: tmp
|
||||
- mountPath: /etc/dch-webhooks
|
||||
name: host-provisioner
|
||||
readOnly: true
|
||||
securityContext:
|
||||
runAsNonRoot: true
|
||||
serviceAccountName: dch-webhooks
|
||||
volumes:
|
||||
- name: firefly-token
|
||||
secret:
|
||||
secretName: firefly-token
|
||||
optional: true
|
||||
- name: host-provisioner
|
||||
configMap:
|
||||
name: host-provisioner
|
||||
optional: true
|
||||
- name: paperless-token
|
||||
secret:
|
||||
secretName: paperless-token
|
||||
optional: true
|
||||
- name: rabbitmq-cert
|
||||
secret:
|
||||
secretName: rabbitmq-cert
|
||||
optional: true
|
||||
- name: root-ca
|
||||
configMap:
|
||||
name: dch-root-ca
|
||||
|
|
|
@ -1,15 +1,29 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
labels:
|
||||
- pairs:
|
||||
app.kubernetes.io/instance: dch-webhooks
|
||||
includeSelectors: true
|
||||
includeTemplates: true
|
||||
- pairs:
|
||||
app.kubernetes.io/part-of: dch-webhooks
|
||||
|
||||
resources:
|
||||
- ../dch-root-ca
|
||||
- dch-webhooks.yaml
|
||||
- certificate.yaml
|
||||
- ingress.yaml
|
||||
|
||||
configMapGenerator:
|
||||
- name: dch-webhooks
|
||||
envs:
|
||||
- dch-webhooks.env
|
||||
- name: host-provisioner
|
||||
files:
|
||||
- ansible-job.yaml
|
||||
options:
|
||||
disableNameSuffixHash: true
|
||||
|
||||
secretGenerator:
|
||||
- name: firefly-token
|
||||
|
|
|
@ -55,4 +55,4 @@ patches:
|
|||
defaultMode: 0640
|
||||
images:
|
||||
- name: docker.io/fireflyiii/core
|
||||
newTag: version-6.2.4
|
||||
newTag: version-6.2.6
|
||||
|
|
|
@ -118,14 +118,14 @@ patches:
|
|||
name: dch-root-ca
|
||||
images:
|
||||
- name: ghcr.io/home-assistant/home-assistant
|
||||
newTag: 2025.1.4
|
||||
newTag: 2025.2.1
|
||||
- name: docker.io/rhasspy/wyoming-whisper
|
||||
newTag: 2.4.0
|
||||
- name: docker.io/rhasspy/wyoming-piper
|
||||
newTag: 1.5.0
|
||||
- name: docker.io/koenkk/zigbee2mqtt
|
||||
newTag: 2.0.0
|
||||
newTag: 2.1.1
|
||||
- name: docker.io/zwavejs/zwave-js-ui
|
||||
newTag: 9.29.1
|
||||
newTag: 9.30.1
|
||||
- name: docker.io/library/eclipse-mosquitto
|
||||
newTag: 2.0.20
|
||||
|
|
|
@ -10,14 +10,7 @@ resources:
|
|||
- secrets.yaml
|
||||
- iscsi.yaml
|
||||
- gentoo-storage.yaml
|
||||
|
||||
configMapGenerator:
|
||||
- name: ssh-known-hosts
|
||||
namespace: jenkins-jobs
|
||||
files:
|
||||
- ssh_known_hosts
|
||||
options:
|
||||
disableNameSuffixHash: true
|
||||
- ../ssh-host-keys
|
||||
|
||||
patches:
|
||||
- patch: |
|
||||
|
|
|
@ -45,8 +45,8 @@ patches:
|
|||
|
||||
images:
|
||||
- name: ghcr.io/paperless-ngx/paperless-ngx
|
||||
newTag: 2.14.5
|
||||
newTag: 2.14.7
|
||||
- name: docker.io/gotenberg/gotenberg
|
||||
newTag: 8.15.3
|
||||
newTag: 8.17.0
|
||||
- name: docker.io/apache/tika
|
||||
newTag: 3.0.0.0
|
||||
newTag: 3.1.0.0
|
||||
|
|
|
@ -12,6 +12,14 @@
|
|||
{
|
||||
"name": "xactmon",
|
||||
"tags": []
|
||||
},
|
||||
{
|
||||
"name": "host-provisioner",
|
||||
"tags": []
|
||||
},
|
||||
{
|
||||
"name": "dch-webhooks",
|
||||
"tags": []
|
||||
}
|
||||
],
|
||||
"permissions": [
|
||||
|
@ -21,6 +29,20 @@
|
|||
"configure": "^xactmon\\..*",
|
||||
"read": "^xactmon\\..*",
|
||||
"write": "^xactmon\\..*"
|
||||
},
|
||||
{
|
||||
"user": "dch-webhooks",
|
||||
"vhost": "/",
|
||||
"configure": "^host-provisioner$",
|
||||
"read": "^host-provisioner$",
|
||||
"write": "^(host-provisioner|amq\\.default)$"
|
||||
},
|
||||
{
|
||||
"user": "host-provisioner",
|
||||
"vhost": "/",
|
||||
"configure": "^host-provisioner$",
|
||||
"read": "^host-provisioner$",
|
||||
"write": "^(host-provisioner|amq\\.default)$"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
@ -0,0 +1,12 @@
|
|||
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||
kind: Kustomization
|
||||
|
||||
configMapGenerator:
|
||||
- name: ssh-known-hosts
|
||||
namespace: jenkins-jobs
|
||||
files:
|
||||
- ssh_known_hosts
|
||||
options:
|
||||
labels:
|
||||
app.kubernetes.io/name: ssh-known-hosts
|
||||
disableNameSuffixHash: true
|
|
@ -100,8 +100,9 @@ projects:
|
|||
- name: vaultwarden
|
||||
kind: kustomize
|
||||
images:
|
||||
- name: authelia
|
||||
- name: vaultwarden
|
||||
image: ghcr.io/dani-garcia/vaultwarden
|
||||
tag_format: '{version}-alpine'
|
||||
source:
|
||||
kind: github
|
||||
organization: dani-garcia
|
||||
|
|
|
@ -27,4 +27,4 @@ configMapGenerator:
|
|||
|
||||
images:
|
||||
- name: ghcr.io/dani-garcia/vaultwarden
|
||||
newTag: 1.32.7-alpine
|
||||
newTag: 1.33.1-alpine
|
||||
|
|
|
@ -185,7 +185,9 @@ groups:
|
|||
for: 10m
|
||||
- alert: WAL archive process failed
|
||||
expr: >-
|
||||
pg_stat_archiver_failed_count > 0
|
||||
max_over_time(
|
||||
increase(pg_stat_archiver_failed_count)[20m]
|
||||
)> 0
|
||||
annotations:
|
||||
summary: The archiver process failed for one or more WAL segments
|
||||
description: >-
|
||||
|
|
Loading…
Reference in New Issue