deploy-sourcegraph
deploy-sourcegraph copied to clipboard
Update storage spec for statefulset in minikube overlay
In our minikube overlays, the current patch to update the storage spec to 10Gi in the kustomization.yaml file only targets PersistentVolumeClaim (pgsql, minios etc), while gitserver and indexed-search are still requesting 200Gi of storage, which might be a lot for a minikube instance considering most of the resources are removed:
volumeClaimTemplates:
- metadata:
labels:
deploy: sourcegraph
name: data
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 200Gi
storageClassName: standard
This PR adds an extra patch in the kustomization.yaml file for adjusting the storage spec for both gitserver and indexed-search, which is currently set to 200Gi respectively by default.
Also added instructions in README on how to adjust the values when needed.
Checklist
- [ ] CHANGELOG.md updated
- [ ] K8s Upgrade notes updated
- [ ] Sister deploy-sourcegraph-docker change:
- [ ] All images have a valid tag and SHA256 sum
Test plan
Manually run the generate cluster command to confirm the storage value are updated for apps_v1_statefulset_gitserver.yaml
file:
...
volumeClaimTemplates:
- metadata:
name: repos
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 50Gi
storageClassName: standard
apps_v1_statefulset_indexed-search.yaml
file:
...
volumeClaimTemplates:
- metadata:
labels:
deploy: sourcegraph
name: data
spec:
accessModes:
- ReadWriteOnce
resources:
requests:
storage: 25Gi
storageClassName: standard