πŸ’€ KubeNidra
πŸ–₯️ KubeNidra Manager

Installation Guide

This guide covers different installation methods for Nidra Manager, from development setup to production deployment.

Prerequisites

Before installing Nidra Manager, ensure you have:

  • Node.js: Version 22 or higher
  • pnpm: Package manager (recommended) or npm
  • KubeNidra API: Running API server (see API documentation)

Development Setup

1. Clone the Repository

git clone https://github.com/kulbirsaini/kubenidra.git
cd kubenidra/nidra-manager

2. Install Dependencies

# Using pnpm (recommended)
pnpm install

# Or using npm
npm install

3. Configure Environment

Copy the example environment file and configure your settings:

cp env.example .env

Edit .env with your configuration:

# API Configuration
VITE_API_BASE_URL=http://192.168.1.13:1881

4. Start Development Server

# Using pnpm
pnpm dev

# Or using npm
npm run dev

The application will be available at http://localhost:7227

Production Build

1. Build the Application

# Using pnpm
pnpm build

# Or using npm
npm run build

This creates a production-ready build in the dist/ directory.

2. Serve the Build

You can serve the built application using any static file server:

# Using a simple HTTP server
npx serve dist

# Or using nginx (see nginx.conf in the repository)

Docker Deployment

1. Build Docker Image

docker build -t ghcr.io/kulbirsaini/kubenidra-manager:latest .

2. Run with Docker Compose

Build image and run the container:

docker-compose up -d --build

OR

Pull the image and run the container

docker-compose up -d

3. Using Pre-built Image

docker run -d \
  -p 3000:80 \
  -e VITE_API_BASE_URL=http://your-api-server:1881 \
  ghcr.io/kulbirsaini/kubenidra-manager:latest

Kubernetes Deployment

Check out the Helm Charts or supplied manager-deployment.yaml for development setup.

Environment Variables

VariableDescriptionDefaultRequired
VITE_API_BASE_URLKubeNidra API server URLhttp://localhost:1881Yes

Configuration

API Configuration

The application needs to connect to the KubeNidra API server. Configure the API endpoint:

VITE_API_BASE_URL=http://your-api-server:1881

Theme Configuration

KubeNidra Manager supports both light and dark themes. Users can switch themes in the application, and the preference is stored locally.

Troubleshooting

Common Issues

  1. API Connection Failed
# Check if API server is running
curl http://your-api-server:1881/api/v1/namespaces

# Verify network connectivity
ping your-api-server
  1. Build Failures
# Clear cache and reinstall dependencies
pnpm clean
pnpm install
pnpm build
  1. Docker Build Issues
# Build with no cache
docker build --no-cache -t ghcr.io/kulbirsaini/kubenidra-manager:latest .
  1. Kubernetes Deployment Issues
# Check pod status
kubectl get pods -n kubenidra

# Check logs
kubectl logs -n kubenidra deployment/kubenidra-manager

Security Considerations

  1. HTTPS Only: Always use HTTPS in production
  2. CORS Configuration: Configure CORS on the API server
  3. Content Security Policy: Implement CSP headers
  4. Regular Updates: Keep dependencies updated