docs: Update deployment strategy for apps using ReadWriteOnce PVCs
This commit is contained in:
@@ -393,6 +393,20 @@ env:
|
|||||||
value: "postgresql://myapp:secret@postgres/myapp"
|
value: "postgresql://myapp:secret@postgres/myapp"
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Deployment Strategy
|
||||||
|
|
||||||
|
Apps using `ReadWriteOnce` (RWO) persistent volumes **must** set `strategy: type: Recreate` on their Deployment. RWO volumes can only be attached to one pod at a time, so the default `RollingUpdate` strategy will cause Multi-Attach errors during updates (the new pod can't mount the volume while the old pod still holds it).
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
spec:
|
||||||
|
replicas: 1
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
component: web
|
||||||
|
```
|
||||||
|
|
||||||
## Security Requirements
|
## Security Requirements
|
||||||
|
|
||||||
### Security Contexts
|
### Security Contexts
|
||||||
@@ -550,6 +564,7 @@ Before submitting a new or modified app, verify:
|
|||||||
|
|
||||||
- [ ] **Resources**
|
- [ ] **Resources**
|
||||||
- [ ] Security contexts on all pods (both pod-level and container-level)
|
- [ ] Security contexts on all pods (both pod-level and container-level)
|
||||||
|
- [ ] `strategy: type: Recreate` on deployments with ReadWriteOnce PVCs
|
||||||
- [ ] Simple component labels, no Helm-style labels
|
- [ ] Simple component labels, no Helm-style labels
|
||||||
- [ ] Ingresses include external-dns annotations
|
- [ ] Ingresses include external-dns annotations
|
||||||
- [ ] Database apps include init jobs (if applicable)
|
- [ ] Database apps include init jobs (if applicable)
|
||||||
|
|||||||
@@ -5,6 +5,8 @@ metadata:
|
|||||||
namespace: "{{ .namespace }}"
|
namespace: "{{ .namespace }}"
|
||||||
spec:
|
spec:
|
||||||
replicas: 1
|
replicas: 1
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
component: api
|
component: api
|
||||||
|
|||||||
@@ -9,6 +9,8 @@ metadata:
|
|||||||
partOf: wild-cloud
|
partOf: wild-cloud
|
||||||
spec:
|
spec:
|
||||||
replicas: 1
|
replicas: 1
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
app: crowdsec
|
app: crowdsec
|
||||||
|
|||||||
@@ -5,6 +5,8 @@ metadata:
|
|||||||
name: immich-machine-learning
|
name: immich-machine-learning
|
||||||
spec:
|
spec:
|
||||||
replicas: 1
|
replicas: 1
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
app: immich-machine-learning
|
app: immich-machine-learning
|
||||||
|
|||||||
@@ -4,6 +4,8 @@ metadata:
|
|||||||
name: keila
|
name: keila
|
||||||
spec:
|
spec:
|
||||||
replicas: 1
|
replicas: 1
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
component: web
|
component: web
|
||||||
|
|||||||
@@ -4,6 +4,8 @@ metadata:
|
|||||||
name: open-webui
|
name: open-webui
|
||||||
spec:
|
spec:
|
||||||
replicas: 1
|
replicas: 1
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
component: web
|
component: web
|
||||||
|
|||||||
@@ -5,6 +5,8 @@ metadata:
|
|||||||
name: postgres-deployment
|
name: postgres-deployment
|
||||||
spec:
|
spec:
|
||||||
replicas: 1
|
replicas: 1
|
||||||
|
strategy:
|
||||||
|
type: Recreate
|
||||||
selector:
|
selector:
|
||||||
matchLabels:
|
matchLabels:
|
||||||
app: postgres
|
app: postgres
|
||||||
|
|||||||
Reference in New Issue
Block a user