Files
wild-directory/synapse/versions/v1/deployment.yaml
Paul Payne e25b07126c Bump 33 apps to latest upstream versions
Patch/minor bumps:
- akaunting: 3.1.21 -> 3.2.3
- aptly: 1.6.2 -> 1.6.3
- baserow: 2.2.2 -> 2.4.1
- crowdsec: v1.7.8 -> v1.8.1
- docker-registry: 3.0.0 -> 3.1.2
- etherpad: 2.2.7 -> 2.6.1
- headlamp: v0.42.0 -> v0.46.0
- headscale: 0.29.1 -> 0.29.5
- indico: 3.3.12 -> 3.3.14
- karrot: v17.4.1 -> v17.4.2
- keila: 0.17.1 -> 0.30.3
- lemmy: 0.19.15 -> 0.19.19
- loomio: 3.0.24 -> 3.12.0
- mastodon: 4.5.3 -> 4.7.3
- mautic: 7.1.2 -> 7.2.1
- memcached: 1.6.32 -> 1.6.45
- mobilizon: 5.2.3 -> 5.2.4
- nocodb: 2026.04.1 -> 2026.09.1
- open-webui: 0.9.5 -> 0.12.3
- outline: 1.8.1 -> 1.11.0
- peertube: 8.2.1 -> 8.2.4
- pixelfed: 0.12.7 -> 0.15.1
- pretix: 2026.5.1 -> 2026.8.0
- synapse: v1.144.0 -> v1.163.0
- traefik: v3.4.1 -> v3.7.16
- typebot: 3.17.1 -> 3.19.1
- vaultwarden: 1.37.1 -> 1.37.4
- writefreely: 0.15.1 -> 0.17.2

Multi-file updates for apps with workers/sidekiq/streaming:
- mastodon (5 files), indico (3 files), karrot (4 files),
  lemmy (2 files), loomio (2 files), typebot (2 files),
  pixelfed (2 files), synapse (2 refs), pretix (2 refs),
  aptly (2 refs)
2026-10-23 14:02:09 +00:00

221 lines
7.0 KiB
YAML

---
apiVersion: apps/v1
kind: Deployment
metadata:
name: synapse
spec:
replicas: 1
selector:
matchLabels:
component: synapse
strategy:
type: Recreate
template:
metadata:
labels:
component: synapse
spec:
initContainers:
- name: generate-signing-key
image: "matrixdotorg/synapse:v1.163.0"
command: ["/bin/sh", "-c"]
args:
- |
if [ ! -f /data/keys/signing.key ]; then
echo "Generating signing key..."
mkdir -p /data/keys
# Use Synapse's generate-keys command
python3 -m synapse.app.homeserver \
--generate-keys \
--config-path=/config/homeserver.yaml
echo "Signing key generated successfully"
ls -la /data/keys/
else
echo "Signing key already exists"
fi
env:
- name: DB_PASSWORD
valueFrom:
secretKeyRef:
name: synapse-secrets
key: dbPassword
- name: REDIS_PASSWORD
valueFrom:
secretKeyRef:
name: synapse-secrets
key: redis.password
- name: REGISTRATION_SHARED_SECRET
valueFrom:
secretKeyRef:
name: synapse-secrets
key: registrationSharedSecret
- name: MACAROON_SECRET_KEY
valueFrom:
secretKeyRef:
name: synapse-secrets
key: macaroonSecretKey
- name: FORM_SECRET
valueFrom:
secretKeyRef:
name: synapse-secrets
key: formSecret
- name: SMTP_PASSWORD
valueFrom:
secretKeyRef:
name: synapse-secrets
key: smtp.password
volumeMounts:
- name: synapse-data
mountPath: /data
- name: synapse-config
mountPath: /config
readOnly: true
securityContext:
runAsUser: 991
runAsGroup: 991
allowPrivilegeEscalation: false
capabilities:
drop: [ALL]
readOnlyRootFilesystem: false
containers:
- name: synapse
image: "matrixdotorg/synapse:v1.163.0"
command: ["/bin/sh", "-c"]
args:
- |
set -e
echo "Starting config substitution..."
# Substitute environment variables in the config using Python
python3 -c "
import os
import re
import sys
print('Reading config from /config/homeserver.yaml', file=sys.stderr)
try:
with open('/config/homeserver.yaml', 'r') as f:
content = f.read()
print(f'Config file read: {len(content)} bytes', file=sys.stderr)
except Exception as e:
print(f'Error reading config: {e}', file=sys.stderr)
sys.exit(1)
# Replace \${VAR} with environment variable values
def replace_var(match):
var_name = match.group(1)
value = os.environ.get(var_name, match.group(0))
print(f'Replacing {var_name}: {\"***\" if \"PASSWORD\" in var_name or \"SECRET\" in var_name else value}', file=sys.stderr)
return value
content = re.sub(r'\\\$\{([A-Z_]+)\}', replace_var, content)
print('Writing processed config to /data/homeserver.yaml', file=sys.stderr)
try:
with open('/data/homeserver.yaml', 'w') as f:
f.write(content)
print('Config file written successfully', file=sys.stderr)
except Exception as e:
print(f'Error writing config: {e}', file=sys.stderr)
sys.exit(1)
" || { echo "Python script failed with exit code $?"; exit 1; }
echo "Config substitution complete"
ls -la /data/homeserver.yaml
# Start Synapse with the processed config
exec /start.py
ports:
- containerPort: 8008
protocol: TCP
name: http
- containerPort: 8448
protocol: TCP
name: federation
env:
- name: SYNAPSE_CONFIG_PATH
value: /data/homeserver.yaml
- name: TZ
value: "UTC"
- name: DB_PASSWORD
valueFrom:
secretKeyRef:
name: synapse-secrets
key: dbPassword
- name: REDIS_PASSWORD
valueFrom:
secretKeyRef:
name: synapse-secrets
key: redis.password
- name: REGISTRATION_SHARED_SECRET
valueFrom:
secretKeyRef:
name: synapse-secrets
key: registrationSharedSecret
- name: MACAROON_SECRET_KEY
valueFrom:
secretKeyRef:
name: synapse-secrets
key: macaroonSecretKey
- name: FORM_SECRET
valueFrom:
secretKeyRef:
name: synapse-secrets
key: formSecret
- name: SMTP_PASSWORD
valueFrom:
secretKeyRef:
name: synapse-secrets
key: smtp.password
volumeMounts:
- name: synapse-config
mountPath: /config
readOnly: true
- name: synapse-data
mountPath: /data
- name: synapse-media
mountPath: /data/media_store
livenessProbe:
httpGet:
path: /health
port: 8008
initialDelaySeconds: 60
periodSeconds: 30
timeoutSeconds: 5
readinessProbe:
httpGet:
path: /health
port: 8008
initialDelaySeconds: 30
periodSeconds: 10
timeoutSeconds: 5
resources:
requests:
memory: 256Mi
cpu: 50m
limits:
memory: "2Gi"
cpu: "2000m"
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop: [ALL]
readOnlyRootFilesystem: false
securityContext:
runAsNonRoot: true
runAsUser: 991
runAsGroup: 991
fsGroup: 991
seccompProfile:
type: RuntimeDefault
volumes:
- name: synapse-config
configMap:
name: synapse-config
- name: synapse-data
persistentVolumeClaim:
claimName: synapse-data-pvc
- name: synapse-media
persistentVolumeClaim:
claimName: synapse-media-pvc