diff --git a/.gitea/workflows/deploy.yml b/.gitea/workflows/deploy.yml index c0f441d..0e4cf70 100644 --- a/.gitea/workflows/deploy.yml +++ b/.gitea/workflows/deploy.yml @@ -147,11 +147,17 @@ jobs: echo "🔍 Debugging kubeconfig structure..." echo "File size: $(wc -c < ~/.kube/config) bytes" - echo "Current context:" - kubectl config current-context || echo "❌ No current context set" + echo "First few lines of kubeconfig (structure check):" + head -20 ~/.kube/config | grep -E "(apiVersion|kind|clusters|contexts|users|current-context)" || echo "No standard kubeconfig structure found" - echo "Available contexts:" - kubectl config get-contexts || echo "❌ No contexts available" + echo "Checking for current-context:" + grep "current-context:" ~/.kube/config || echo "❌ No current-context found" + + echo "Checking for clusters:" + grep -A 2 "clusters:" ~/.kube/config || echo "❌ No clusters found" + + echo "Checking for users:" + grep -A 2 "users:" ~/.kube/config || echo "❌ No users found" # Fix TLS issues by adding insecure-skip-tls-verify to all clusters echo "🔧 Fixing TLS verification for self-signed certificates..." @@ -386,11 +392,17 @@ jobs: echo "🔍 Debugging kubeconfig structure..." echo "File size: $(wc -c < ~/.kube/config) bytes" - echo "Current context:" - kubectl config current-context || echo "❌ No current context set" + echo "First few lines of kubeconfig (structure check):" + head -20 ~/.kube/config | grep -E "(apiVersion|kind|clusters|contexts|users|current-context)" || echo "No standard kubeconfig structure found" - echo "Available contexts:" - kubectl config get-contexts || echo "❌ No contexts available" + echo "Checking for current-context:" + grep "current-context:" ~/.kube/config || echo "❌ No current-context found" + + echo "Checking for clusters:" + grep -A 2 "clusters:" ~/.kube/config || echo "❌ No clusters found" + + echo "Checking for users:" + grep -A 2 "users:" ~/.kube/config || echo "❌ No users found" # Fix TLS issues by adding insecure-skip-tls-verify to all clusters echo "🔧 Fixing TLS verification for self-signed certificates..."