fava service
This commit is contained in:
@@ -112,6 +112,41 @@ spec:
|
||||
port: 5000
|
||||
initialDelaySeconds: 5
|
||||
periodSeconds: 5
|
||||
- name: git-sync
|
||||
image: alpine/git:latest
|
||||
command:
|
||||
- /bin/sh
|
||||
- -c
|
||||
- |
|
||||
while true; do
|
||||
echo "Syncing repository at $(date)"
|
||||
cd /data/contabilitat
|
||||
git config --global --add safe.directory /data/contabilitat
|
||||
git pull || echo "Failed to pull, will retry in 1 hour"
|
||||
echo "Next sync in 1 hour"
|
||||
sleep 3600
|
||||
done
|
||||
env:
|
||||
- name: GITEA_USERNAME
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: gitea-credentials
|
||||
key: username
|
||||
- name: GITEA_PASSWORD
|
||||
valueFrom:
|
||||
secretKeyRef:
|
||||
name: gitea-credentials
|
||||
key: password
|
||||
volumeMounts:
|
||||
- name: data
|
||||
mountPath: /data
|
||||
resources:
|
||||
requests:
|
||||
cpu: 10m
|
||||
memory: 32Mi
|
||||
limits:
|
||||
cpu: 100m
|
||||
memory: 128Mi
|
||||
volumes:
|
||||
- name: data
|
||||
persistentVolumeClaim:
|
||||
|
||||
Reference in New Issue
Block a user