Admin UI

Updated for nself-admin v0.0.8

The Admin UI (nself-admin v0.0.8) is a comprehensive web-based dashboard for nself. It provides real-time monitoring, service management, plugin management, and database operations through an intuitive interface at localhost:3021.

New in v0.0.8: Plugin Management UI

  • Plugin Dashboard: View installed and available plugins
  • Plugin Installation: One-click install with env var configuration
  • Stripe Integration: Revenue dashboard, customer management, invoices
  • GitHub Integration: Repository overview, issues, PR tracking
  • Shopify Integration: Store metrics, products, orders
  • Webhook Monitoring: Real-time event log with retry capability
  • Enhanced Database UI: Monaco SQL editor, backup wizard, migrations

Quick Start

Enable the Admin UI with a single command:

# Enable the admin UI
nself admin enable

# Set a custom password
nself admin password mypassword

# Open in browser
nself admin open

Features

Plugin Management (v0.0.8)

Manage third-party integrations through the web interface:

  • Plugin Dashboard (/plugins) - Grid view of installed and available plugins
  • Installation Wizard - Configure environment variables and install plugins
  • Plugin Detail Pages (/plugins/[name]) - Per-plugin configuration and data
  • Sync Controls - Manual sync with history tracking
  • Health Indicators - Real-time plugin health status

Stripe Plugin UI

  • Revenue dashboard with MRR/ARR metrics and charts
  • Customer management with search and filtering
  • Subscription viewer with status indicators
  • Invoice management with PDF download
  • Payment methods viewer
  • Webhook event log with filtering and retry

GitHub Plugin UI

  • Repository overview with sync status
  • Issues and Pull Requests dashboard
  • GitHub Actions workflow runs
  • Commit history and releases
  • Activity feed

Shopify Plugin UI

  • Store overview with sales metrics
  • Product catalog with variant details
  • Order management with status filters
  • Customer list and search
  • Inventory status tracking

Real-time Service Monitoring

Monitor the health and status of all your services in real-time:

  • Service health indicators with color-coded status
  • Resource usage (CPU, memory, network)
  • Container uptime and restart counts
  • Port and URL information for each service

Docker Container Management

Manage your Docker containers directly from the web interface:

  • Start, stop, and restart individual containers
  • View detailed container logs with real-time streaming
  • Execute commands inside running containers
  • Container resource limits and usage statistics

Enhanced Database UI (v0.0.8)

Comprehensive database management with new features:

  • Monaco SQL Console - Syntax highlighting and auto-completion
  • Query History - Persisted query history with saved queries
  • Results Export - Export to CSV or JSON formats
  • Query Explain - Analyze query performance
  • Backup Wizard - Create backups with type selection
  • Backup Management - List, download, delete, and restore backups
  • Scheduled Backups - Visual cron editor for automation
  • Migration Management - Run, rollback, and create migrations
  • Schema Browser - Visual table exploration with relationships

Multi-Environment Deployment (v0.0.7)

Deploy to staging and production from the UI:

  • Staging Deployment (/deployment/staging) - Deploy and manage staging
  • Production Deployment (/deployment/prod) - Deploy to production
  • Environment Management (/deployment/environments) - View all environments
  • Deploy status and health checks
  • Remote log viewing

Log Viewer

Centralized logging with advanced filtering and search:

  • Real-time log streaming from all services
  • Filter by service, log level, or custom patterns
  • Full-text search across historical logs
  • Export and download log files

Configuration Editor

Edit environment variables and configuration files:

  • Visual editor for .env files
  • Validation and syntax checking
  • Apply configuration changes with automatic restart
  • Configuration diff and rollback capabilities

SSL Configuration (v0.0.6)

Manage SSL certificates from the UI:

  • Certificate status display (mode, validity, expiry)
  • Local certificate generation via mkcert
  • Let's Encrypt configuration support
  • Trust store installation guide

Admin Commands

The nself admin command provides complete control over the Admin UI:

# Enable the admin UI
nself admin enable

# Disable the admin UI
nself admin disable

# Check admin UI status
nself admin status

# Set or change password
nself admin password [PASSWORD]

# Reset admin to defaults
nself admin reset

# View admin container logs
nself admin logs

# Open admin UI in browser
nself admin open

Authentication

The Admin UI is protected by password authentication:

  • Default URL: http://localhost:3021
  • Default Username: admin
  • Password: Set with nself admin password

If no password is set, the Admin UI generates a temporary password displayed during the nself admin enable command.

Configuration

The Admin UI can be configured through environment variables:

# Enable/disable admin UI
NSELF_ADMIN_ENABLED=true

# Admin UI port (default: 3021)
NSELF_ADMIN_PORT=3021

# Admin username (default: admin)
NSELF_ADMIN_USER=admin

# Admin password (set via nself admin password)
NSELF_ADMIN_PASSWORD=your-secure-password

# Project path (for container access)
NSELF_PROJECT_PATH=/workspace

API Endpoints

The Admin UI provides a REST API for programmatic access:

Core Endpoints

  • GET /api/health - Health check (includes CLI version)
  • GET /api/services - List all services
  • POST /api/services/[name]/[action] - Control services (start/stop/restart)
  • GET /api/logs/[service] - Stream service logs
  • GET /api/config - Get current configuration
  • POST /api/config - Update configuration

Plugin Endpoints (v0.0.8)

  • GET /api/plugins - List all plugins
  • POST /api/plugins/install - Install a plugin
  • DELETE /api/plugins/[name] - Remove a plugin
  • GET /api/plugins/[name] - Plugin status
  • POST /api/plugins/[name]/sync - Trigger sync
  • GET /api/plugins/[name]/webhooks - Webhook events

Database Endpoints (v0.0.8)

  • GET /api/database/backups - List backups
  • POST /api/database/backups - Create backup
  • POST /api/database/backups/restore - Restore backup
  • GET /api/database/migrations - Migration status
  • POST /api/database/migrations/run - Run migrations
  • GET /api/database/schema - Schema information

Deployment Endpoints (v0.0.7)

  • POST /api/deploy/staging - Deploy to staging
  • POST /api/deploy/production - Deploy to production
  • GET /api/env - Environment information

Security Considerations

The Admin UI is designed for local development and should be secured properly:

  • Local Development: Enabled at admin.local.nself.org
  • Staging: Disabled by default, enable temporarily for debugging
  • Production: DISABLED for security - never expose publicly

Security Best Practices

  • Change the default password immediately
  • Disable in production environments
  • Use reverse proxy with SSL for remote access
  • Monitor access logs for unauthorized attempts
  • Use SSH tunnel or VPN for remote debugging

Technology Stack

LayerTechnology
FrontendNext.js 16, React 19, TypeScript
StylingTailwind CSS v4
StateZustand
SQL EditorMonaco Editor
ChartsRecharts
DatabaseLokiJS (embedded)
ContainerDocker API via Dockerode
Real-timeWebSockets, Server-Sent Events

Troubleshooting

Admin UI won't start

If the Admin UI fails to start, check the following:

  • Ensure port 3021 is available (not used by another service)
  • Verify Docker is running and has sufficient resources
  • Check admin container logs: nself admin logs
  • Reset admin configuration: nself admin reset

Cannot access Admin UI

If you can't access the Admin UI in your browser:

  • Verify the service is running: nself admin status
  • Check if port 3021 is accessible: curl http://localhost:3021/api/health
  • Try opening with: nself admin open
  • Check firewall settings if accessing remotely

Password Issues

If you've forgotten your password or need to reset access:

  • Reset password: nself admin password newpassword
  • Reset entire admin configuration: nself admin reset
  • Disable and re-enable: nself admin disable && nself admin enable

CLI Integration Issues

If the Admin UI can't execute CLI commands:

  • Check nself CLI is installed: nself version
  • Verify PROJECT_PATH or NSELF_PROJECT_PATH is set correctly
  • Check health endpoint for CLI version: curl http://localhost:3021/api/health
  • Review container PATH settings

Version History

VersionReleaseKey Features
v0.0.8Jan 2026Plugin Management UI, Enhanced Database UI, Monaco editor
v0.0.7Jan 2026Multi-environment deployment, CLI path resolution
v0.0.6Jan 2026SSL configuration page, centralized constants
v0.0.5Jan 2026Documentation reorganization
v0.0.4Sep 2025Security enhancements, bcrypt hashing
v0.0.3Aug 2025LokiJS integration, project wizard

Related Commands

The Admin UI integrates with these nself commands:

  • nself status - View service health (also available in Admin UI)
  • nself logs - Stream logs (also available in Admin UI)
  • nself db - Database operations (also available in Admin UI)
  • nself backup - Backup management (also available in Admin UI)
  • nself plugin - Plugin management (also available in Admin UI)
  • nself deploy - Deployment (also available in Admin UI)

The Admin UI provides a graphical interface to many CLI operations, making it easier to manage your nself infrastructure, especially for team members who prefer web interfaces over command-line tools.