fix: deploy plugin via temporary pod instead of assuming local PVC mount
The deploy script assumed the PVC was mounted on the CI runner at /mnt/headlamp-plugins, but the runner pod doesn't have that mount. Fix by using a temporary pod (kubectl run) that mounts the PVC, receives the plugin tarball via stdin, and extracts it. Also adds missing workflow steps to create the PVC and upgrade Headlamp with the shared volume helm values before deploying. Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
@@ -8,7 +8,6 @@ on:
|
||||
workflow_dispatch:
|
||||
|
||||
env:
|
||||
PLUGIN_VOLUME_PATH: /mnt/headlamp-plugins
|
||||
HEADLAMP_NAMESPACE: kube-system
|
||||
HEADLAMP_DEPLOY: headlamp
|
||||
|
||||
@@ -33,6 +32,17 @@ jobs:
|
||||
- name: Build plugin
|
||||
run: npm run build
|
||||
|
||||
- name: Ensure PVC exists
|
||||
run: kubectl apply -f deployment/headlamp-plugins-pvc.yaml
|
||||
|
||||
- name: Upgrade Headlamp with shared volume mount
|
||||
run: |
|
||||
helm upgrade headlamp headlamp/headlamp \
|
||||
--namespace "$HEADLAMP_NAMESPACE" \
|
||||
--reuse-values \
|
||||
-f deployment/headlamp-e2e-values.yaml \
|
||||
--wait --timeout 120s
|
||||
|
||||
- name: Deploy plugin via shared volume
|
||||
run: scripts/deploy-plugin-via-volume.sh
|
||||
|
||||
|
||||
Reference in New Issue
Block a user