Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
cubicweb
cubes
fresh
Commits
774311c0e28c
Commit
629a0343
authored
Sep 17, 2020
by
Elouan Martinet
Browse files
[deploy] Move daily backup CronJob into a separate file
This backup is optional.
parent
ecb358a1681c
Pipeline
#14505
passed with stage
in 5 minutes and 1 second
Changes
4
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
MANIFEST.in
View file @
774311c0
...
...
@@ -13,3 +13,4 @@ recursive-include docker *.ini *.j2 *.sh *.txt
recursive-include deploy *.yaml
prune debian
exclude .gitlab-ci.yml
prune deploy
deploy/README
0 → 100644
View file @
774311c0
deployment.yaml is used to deploy fresh on Kubernetes.
backup.yaml defines a CronJob for daily backup of the database, it is optional.
deploy/backup.yaml
0 → 100644
View file @
774311c0
apiVersion
:
batch/v1beta1
kind
:
CronJob
metadata
:
name
:
fresh-backup
spec
:
schedule
:
"
0
6
*
*
*"
concurrencyPolicy
:
Forbid
jobTemplate
:
spec
:
template
:
metadata
:
labels
:
app
:
fresh
spec
:
restartPolicy
:
Never
volumes
:
-
name
:
backup
persistentVolumeClaim
:
claimName
:
backup
containers
:
-
name
:
fresh
image
:
r.intra.logilab.fr/intranet/fresh
imagePullPolicy
:
Always
command
:
[
"
cubicweb-ctl"
,
"
db-dump"
,
"
fresh"
]
envFrom
:
-
secretRef
:
name
:
fresh-env
volumeMounts
:
-
name
:
backup
mountPath
:
/etc/cubicweb.d/fresh/backup
resources
:
requests
:
cpu
:
50m
memory
:
500Mi
deploy/deployment.yaml
View file @
774311c0
...
...
@@ -180,38 +180,3 @@ spec:
ports
:
-
protocol
:
TCP
port
:
8000
---
apiVersion
:
batch/v1beta1
kind
:
CronJob
metadata
:
name
:
fresh-backup
spec
:
schedule
:
"
0
6
*
*
*"
concurrencyPolicy
:
Forbid
jobTemplate
:
spec
:
template
:
metadata
:
labels
:
app
:
fresh
spec
:
restartPolicy
:
Never
volumes
:
-
name
:
backup
persistentVolumeClaim
:
claimName
:
backup
containers
:
-
name
:
fresh
image
:
r.intra.logilab.fr/intranet/fresh
imagePullPolicy
:
Always
command
:
[
"
cubicweb-ctl"
,
"
db-dump"
,
"
fresh"
]
envFrom
:
-
secretRef
:
name
:
fresh-env
volumeMounts
:
-
name
:
backup
mountPath
:
/etc/cubicweb.d/fresh/backup
resources
:
requests
:
cpu
:
50m
memory
:
500Mi
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment