From 44b54db475e580e23e491b687325cf0448e22b2c Mon Sep 17 00:00:00 2001 From: Patrick Schratz Date: Thu, 29 Jun 2023 19:22:33 +0200 Subject: [PATCH] Document k8s volume usage (#1896) --- docs/docs/30-administration/80-kubernetes.md | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/docs/docs/30-administration/80-kubernetes.md b/docs/docs/30-administration/80-kubernetes.md index 9b14998a4..8b28c18d9 100644 --- a/docs/docs/30-administration/80-kubernetes.md +++ b/docs/docs/30-administration/80-kubernetes.md @@ -53,3 +53,20 @@ helm upgrade --install woodpecker-agent --namespace woodpecker/woodp # Uninstall helm delete woodpecker-agent ``` + +## Volumes + +To mount volumes a persistent volume (PV) and persistent volume claim (PVC) are needed on the cluster which can be referenced in steps via the `volume:` option. +Assuming a PVC named "woodpecker-cache" exists, it can be referenced as follows in a step: + +```yaml +steps: + "Restore Cache": + image: meltwater/drone-cache + volumes: + - woodpecker-cache:/woodpecker/src/cache + settings: + mount: + - "woodpecker-cache" + [...] +```