Skip to content

Repository files navigation

Crossplane Infrastructure UI

A web-based UI for provisioning AWS S3 buckets and Azure Storage Accounts using Crossplane.

🚀 One-Command Setup

Everything automated! Just run this single command:

./scripts/start-all.sh

This script will:

  • ✅ Check all requirements
  • ✅ Create a Kind Kubernetes cluster
  • ✅ Install Crossplane and providers
  • ✅ Apply all resource definitions
  • ✅ Start the backend server
  • ✅ Start the frontend development server
  • ✅ Open the UI at http://localhost:5173

Prerequisites

Before running any stack setup script, verify all required tools are installed:

./scripts/check-prerequisites.sh

This will check for:

  • Required for stack scripts: kubectl, helm, kind
  • Required for backend development: Go 1.19+
  • Required for frontend development: Node.js 16+, npm
  • Required for Kind clusters: Docker (daemon must be running)

The script provides installation instructions for any missing tools.

🎯 What You Get

After running the script, you'll have:

🛑 Stop Everything

To stop all services and clean up:

./scripts/cleanup.sh

🔧 Targeted Cloud Stacks (Lightweight)

To keep clusters lean and avoid TLS timeout issues, provision only the providers you need. Each stack script automatically checks prerequisites first, then spins up its own Kind cluster, installs Crossplane, and applies a minimal provider bundle. A matching cleanup script tears the cluster down.

Note: You can also run the prerequisites check manually:

./scripts/check-prerequisites.sh

Full Cloud Stacks (All Services)

Cloud Setup Cleanup Providers Included
AWS ./scripts/setup-aws-stack.sh ./scripts/cleanup-aws-stack.sh provider-aws-s3, provider-aws-ec2
Azure ./scripts/setup-azure-stack.sh ./scripts/cleanup-azure-stack.sh provider-family-azure, provider-azure-compute, provider-azure-network, provider-azure-storage (4 providers)
GCP ./scripts/setup-gcp-stack.sh ./scripts/cleanup-gcp-stack.sh provider-family-gcp, provider-gcp-compute, provider-gcp-container, provider-gcp-storage

Azure Resource-Specific Stacks (Ultra-Lightweight - Recommended)

For Azure, use these granular scripts to avoid cluster overload. Each installs only 2 providers (family + specific service):

Resource Type Setup Cleanup Providers Included
Storage ./scripts/setup-azure-storage-only.sh ./scripts/cleanup-azure-storage-only.sh provider-family-azure, provider-azure-storage (2 providers)
Compute ./scripts/setup-azure-compute-only.sh ./scripts/cleanup-azure-compute-only.sh provider-family-azure, provider-azure-compute (2 providers)
Network ./scripts/setup-azure-network-only.sh ./scripts/cleanup-azure-network-only.sh provider-family-azure, provider-azure-network (2 providers)

Tip: Use the resource-specific scripts (e.g., setup-azure-storage-only.sh) to minimize cluster load and avoid TLS handshake timeouts. Run only one stack at a time. If you need to switch resources, execute the cleanup script before launching the next stack.

Features

  • AWS S3 Management: List, create, and delete S3 buckets
  • Azure Storage Management: List, create, and delete Azure Storage Accounts
  • Credential Management: Secure storage of cloud provider credentials
  • Real-time Status: Live status updates from Kubernetes

API Endpoints

Health Check

  • GET /api/health - Service health status

AWS S3

  • GET /api/s3 - List S3 buckets
  • POST /api/s3 - Create S3 bucket
  • DELETE /api/s3/:name - Delete S3 bucket

Azure Storage

  • GET /api/azure/storage - List Azure Storage Accounts
  • POST /api/azure/storage - Create Azure Storage Account
  • DELETE /api/azure/storage/:name - Delete Azure Storage Account

Credentials

  • POST /api/credentials/aws - Store AWS credentials
  • POST /api/credentials/azure - Store Azure credentials
  • DELETE /api/credentials/:name - Delete credentials

Architecture

  • Backend: Go REST API with Gin framework
  • Frontend: React with Vite
  • Infrastructure: Crossplane for cloud resource provisioning
  • Storage: Kubernetes secrets for credential management
  • State: Direct Kubernetes queries (no database)

Manual Development (if needed)

Backend Development

With Hot-Reload (Recommended):

cd backend
# Install air if not already installed
go install github.com/cosmtrek/air@latest

# Run with hot-reload (auto-restarts on file changes)
air

Without Hot-Reload:

cd backend
go mod tidy
go run main.go

Note: The start-all.sh script automatically uses Air for hot-reload if available. Changes to Go files will automatically restart the server.

Frontend Development

cd frontend
npm install
npm run dev

Troubleshooting

If something goes wrong:

  1. Check logs: Look at backend.log and frontend.log
  2. Restart everything: Run ./scripts/cleanup.sh then ./scripts/start-all.sh
  3. Check Kubernetes: kubectl get pods -n crossplane-system

Cleanup

To clean up all resources:

./scripts/cleanup.sh

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages