Skip to content

Helm Deployment Test #7

Helm Deployment Test

Helm Deployment Test #7

name: Helm Deployment Test
on:
pull_request_target:
types: [labeled]
branches: [main, gh-pages]
schedule:
- cron: '0 10 * * 1' # Mondays 10 AM UTC (1 hour after lint)
workflow_dispatch:
jobs:
deploy-test:
runs-on: ubuntu-latest
# Security: Only run pull_request_target if 'deploy-test' label present
if: |
github.event_name != 'pull_request_target' ||
contains(github.event.pull_request.labels.*.name, 'deploy-test')
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Helm
uses: azure/setup-helm@v3
with:
version: 'v3.14.0'
- name: Add Bitnami Helm repository
run: |
helm repo add bitnami https://charts.bitnami.com/bitnami
helm repo update
timeout-minutes: 5
- name: Determine chart path
id: chart-path
run: |
if [ -f "Chart.yaml" ]; then
echo "path=." >> $GITHUB_OUTPUT
elif [ -d "charts/tooljet" ]; then
echo "path=charts/tooljet" >> $GITHUB_OUTPUT
else
echo "Error: Chart not found"
exit 1
fi
- name: Update Helm chart dependencies
run: |
cd ${{ steps.chart-path.outputs.path }}
helm dependency update
- name: Create Kind Kubernetes cluster
uses: helm/kind-action@v1.8.0
with:
cluster_name: tooljet-test
wait: 120s
- name: Verify cluster is ready
run: |
kubectl cluster-info
kubectl get nodes
- name: Deploy ToolJet chart
run: |
echo "πŸš€ Installing chart (without waiting for pods to be ready)..."
helm install tooljet ${{ steps.chart-path.outputs.path }} \
--namespace tooljet \
--create-namespace \
--set postgresql.enabled=true \
--set redis.enabled=false \
--debug
- name: Verify resources were created
run: |
echo "βœ… Helm install completed successfully"
echo ""
echo "πŸ“Š Checking deployed resources..."
kubectl get all -n tooljet
echo ""
echo "πŸ“‹ Checking Deployments..."
kubectl get deployments -n tooljet -o wide
echo ""
echo "πŸ“‹ Checking Services..."
kubectl get services -n tooljet
echo ""
echo "πŸ“‹ Checking Secrets..."
kubectl get secrets -n tooljet
echo ""
echo "πŸ“‹ Pod Status:"
kubectl get pods -n tooljet -o wide || true
echo ""
echo "ℹ️ Note: Pods may not be ready without proper configuration"
echo "ℹ️ This test validates that resources deploy correctly, not that the app runs"
- name: Describe pods for debugging
if: always()
run: |
echo "πŸ” Describing pods for debugging..."
kubectl describe pods -n tooljet || true
echo ""
echo "πŸ“‹ Recent pod events:"
kubectl get events -n tooljet --sort-by='.lastTimestamp' || true
- name: Cleanup
if: always()
run: |
helm uninstall tooljet -n tooljet || true