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
f711839dc2e2
Commit
f440c1b0
authored
Nov 27, 2019
by
Philippe Pepiot
Browse files
Add upgrade and backup
parent
8e7356b5098e
Changes
1
Hide whitespace changes
Inline
Side-by-side
deploy/deployment.yaml
View file @
f711839d
...
...
@@ -55,6 +55,24 @@ spec:
-
name
:
bfss
persistentVolumeClaim
:
claimName
:
fresh
-
name
:
backup
persistentVolumeClaim
:
claimName
:
backup
initContainers
:
-
name
:
upgrade
image
:
r.intra.logilab.fr/intranet/fresh
imagePullPolicy
:
Always
command
:
[
"
cubicweb-ctl"
,
"
upgrade"
,
"
--backup-db=y"
,
"
--force"
,
"
--verbosity=0"
,
"
fresh"
]
envFrom
:
-
secretRef
:
name
:
fresh-env
resources
:
requests
:
cpu
:
50m
memory
:
500Mi
volumeMounts
:
-
name
:
backup
mountPath
:
/etc/cubicweb.d/fresh/backup
containers
:
-
name
:
fresh
image
:
r.intra.logilab.fr/intranet/fresh
...
...
@@ -69,6 +87,8 @@ spec:
mountPath
:
/secret
-
name
:
bfss
mountPath
:
/etc/cubicweb.d/fresh/bfss
-
name
:
backup
mountPath
:
/etc/cubicweb.d/fresh/backup
command
:
[
"
/bin/sh"
,
"
-c"
,
"
install
-m
400
/secret/cwclientlibrc
/etc/cubicweb.d/fresh/cwclientlibrc
&&
exec
/entrypoint.sh
start"
...
...
@@ -160,3 +180,38 @@ 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
Markdown
is supported
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