feat: scheduler-k3s renders pvc-backed volumes from storage attachments
Adds a per-entry storage helm chart that owns the PVC and (when host_path is set) the PV, and three triggers for the storage plugin to drive: storage-create installs/upgrades the chart with storage-class existence validation, storage-destroy uninstalls it, storage-status reports the PVC phase. App deployment and cron-job charts now consume storage-app-mounts and reference each PVC by name; the // todo: implement volumes blocks are gone. ProcessVolume gained sub_path, read_only, and persistent_claim fields and the deployment/cron-job templates render them.
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"context"
|
||||
"fmt"
|
||||
"os"
|
||||
"strconv"
|
||||
@@ -158,6 +159,15 @@ func main() {
|
||||
appName := flag.Arg(1)
|
||||
format := flag.Arg(2)
|
||||
err = scheduler_k3s.TriggerSchedulerRunList(scheduler, appName, format)
|
||||
case "storage-create":
|
||||
entryName := flag.Arg(0)
|
||||
err = scheduler_k3s.TriggerStorageCreate(context.Background(), entryName)
|
||||
case "storage-destroy":
|
||||
entryName := flag.Arg(0)
|
||||
err = scheduler_k3s.TriggerStorageDestroy(context.Background(), entryName)
|
||||
case "storage-status":
|
||||
entryName := flag.Arg(0)
|
||||
err = scheduler_k3s.TriggerStorageStatus(context.Background(), entryName)
|
||||
default:
|
||||
err = fmt.Errorf("Invalid plugin trigger call: %s", trigger)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user