feat: update manifests and namespaces to use templated namespace variables

This commit is contained in:
2026-05-17 23:26:20 +00:00
parent edff518815
commit 872a804aa7
31 changed files with 28 additions and 277 deletions

View File

@@ -1,47 +0,0 @@
#!/bin/bash
set -e
set -o pipefail
if [ -z "${WILD_INSTANCE}" ]; then
echo "ERROR: WILD_INSTANCE is not set"
exit 1
fi
if [ -z "${WILD_API_DATA_DIR}" ]; then
echo "ERROR: WILD_API_DATA_DIR is not set"
exit 1
fi
if [ -z "${KUBECONFIG}" ]; then
echo "ERROR: KUBECONFIG is not set"
exit 1
fi
INSTANCE_DIR="${WILD_API_DATA_DIR}/instances/${WILD_INSTANCE}"
LONGHORN_DIR="${INSTANCE_DIR}/apps/longhorn"
echo "=== Setting up Longhorn ==="
echo ""
echo "Using pre-compiled Longhorn templates..."
if [ ! -f "${LONGHORN_DIR}/kustomization.yaml" ]; then
echo "ERROR: Compiled templates not found at ${LONGHORN_DIR}"
echo "Templates should be compiled before deployment."
exit 1
fi
echo "Deploying Longhorn..."
kubectl apply -k ${LONGHORN_DIR}/
echo "Waiting for Longhorn to be ready..."
kubectl wait --for=condition=available --timeout=300s deployment/longhorn-driver-deployer -n longhorn-system || true
echo ""
echo "Longhorn installed successfully"
echo ""
echo "To verify the installation:"
echo " kubectl get pods -n longhorn-system"
echo " kubectl get storageclass"
echo ""
echo "To access the Longhorn UI:"
echo " kubectl port-forward -n longhorn-system svc/longhorn-frontend 8080:80"

View File

@@ -2,12 +2,12 @@ name: longhorn
is: longhorn
description: Cloud-native distributed block storage for Kubernetes
version: v1.8.1
namespace: longhorn-system
deploymentName: longhorn-ui
category: infrastructure
requires:
- name: traefik
- name: nfs
defaultConfig:
namespace: longhorn-system
internalDomain: "{{ .cloud.internalDomain }}"
backupTarget: "nfs://{{ .apps.nfs.host }}:/data/{{ .cluster.name }}/backups"