A comprehensive collection of enterprise-grade Bash scripts for Remnawave Panel, RemnaNode, and Reality traffic masking management. Featuring advanced backup/restore capabilities, automated scheduling, Telegram integration, and production-ready deployment tools.
- πΎ Backup & Restore System
- π Scheduled Backups
- π Migration & Restore
- π± Telegram Integration
- π Security Features
- ποΈ Management Commands
- π Monitoring & Logs
- βοΈ System Requirements
A comprehensive enterprise-grade Bash script to install and manage the Remnawave Panel. Features full automation, advanced backup/restore capabilities, scheduled operations, and production-ready deployment tools.
ποΈ Complete CLI Management
- Full command interface:
install,up,down,restart,logs,status,edit,update,uninstall - Interactive main menu with colorized output
- Script self-updating with version checking
- Console access to internal panel CLI
π§ Advanced Installation
- Auto-generation of
.env, secrets, ports, anddocker-compose.yml - Development mode support with
--devflag - Custom installation paths and names
- Automatic dependency detection and installation
- System requirements validation
πΎ Enterprise Backup & Restore System
- Full system backups with compression (.tar.gz)
- Database-only backups (.sql, .sql.gz)
- Scheduled backups with cron integration
- Complete migration system between servers
- Safety backups with automatic rollback
- Retention policies with automatic cleanup
π± Telegram Integration
- Bot notifications for operations and scheduled backups
- Large file support with chunked delivery
- Thread support for group chats
- Comprehensive status reporting
π Automatic Variable Migration (Remnawave v2.2.0+)
- Auto-detection of deprecated environment variables
- Safe migration with automatic backup creation
- OAuth and Branding settings moved to UI
- Seamless upgrade experience with zero downtime
# Install Remnawave Panel
bash <(curl -Ls https://github.com/DigneZzZ/remnawave-scripts/raw/main/remnawave.sh) @ install
# Install only the management script
bash <(curl -Ls https://github.com/DigneZzZ/remnawave-scripts/raw/main/remnawave.sh) @ install-script --name remnawave| Flag | Description | Example |
|---|---|---|
--name |
Custom installation directory name | --name panel-prod |
--dev |
Install development version | --dev |
Examples:
# Development installation with custom name
bash <(curl -Ls https://github.com/DigneZzZ/remnawave-scripts/raw/main/remnawave.sh) @ install --name remnawave-dev --dev
# Production installation with custom name
bash <(curl -Ls https://github.com/DigneZzZ/remnawave-scripts/raw/main/remnawave.sh) @ install --name panel-prod| Command | Description | Usage |
|---|---|---|
install |
Install Remnawave Panel | remnawave install [--dev] [--name NAME] |
update |
Update script and containers | remnawave update |
uninstall |
Remove panel completely | remnawave uninstall |
up |
Start all services | remnawave up |
down |
Stop all services | remnawave down |
restart |
Restart panel | remnawave restart |
status |
Show service status | remnawave status |
| Command | Description | Usage |
|---|---|---|
edit |
Edit docker-compose.yml | remnawave edit |
edit-env |
Edit .env file | remnawave edit-env |
logs |
View container logs | remnawave logs [--follow] |
console |
Access panel CLI console | remnawave console |
| Command | Description | Usage |
|---|---|---|
backup |
Create manual backup | remnawave backup [--no-compress] [--data-only] |
restore |
Restore from backup | remnawave restore [--file FILE] [--database-only] |
schedule |
Manage scheduled backups | remnawave schedule |
# Full system backup (compressed by default)
remnawave backup
# Database only backup
remnawave backup --data-only
# Uncompressed backup (not recommended)
remnawave backup --no-compress# Configure automated backups
remnawave schedule
# Available schedule options:
# - Daily, Weekly, Monthly intervals
# - Compression settings
# - Retention policies (days, minimum backups)
# - Telegram delivery configuration
# - Automatic backup script version checking# Complete system migration
remnawave restore --file backup.tar.gz --name newpanel --path /opt
# Database only restore
remnawave restore --database-only --file database.sql.gz
# Restore with safety backup
remnawave restore --file backup.tar.gz # Automatic safety backup createdπ Version Compatibility:
- Panel version included in all backup metadata and notifications
- Strict version checking: Major/minor versions must match for restore
- Patch version differences show warnings but allow restore
- Script version managed separately from panel version
οΏ½ Recommended Restore Method:
# Transfer backup file to target server, then:
sudo remnawave restore --file backup.tar.gz
# For database-only backups:
sudo remnawave restore --database-only --file database.sql.gzπ Manual Restore (if automatic fails):
# Option A: New installation (recommended)
curl -Ls https://github.com/DigneZzZ/remnawave-scripts/raw/main/remnawave.sh
sudo bash remnawave.sh @ install --name remnawave
sudo remnawave down
tar -xzf backup.tar.gz
cat backup_folder/database.sql | docker exec -i -e PGPASSWORD="actual_password" remnawave-db psql -U postgres -d postgres
# Option B: Existing installation
sudo remnawave down
cat database.sql | docker exec -i -e PGPASSWORD="actual_password" remnawave-db psql -U postgres -d postgres
sudo remnawave uprestore function includes automatic version checking, safety backups, and error handling.
Starting with Remnawave v2.2.0, many environment variables have been moved to the UI panel for better management and security.
Deprecated Variables (Auto-migrated):
# OAuth Settings β Now in Panel UI
TELEGRAM_OAUTH_ENABLED
TELEGRAM_OAUTH_ADMIN_IDS
OAUTH2_GITHUB_ENABLED
OAUTH2_GITHUB_CLIENT_ID
OAUTH2_GITHUB_CLIENT_SECRET
OAUTH2_GITHUB_ALLOWED_EMAILS
OAUTH2_POCKETID_ENABLED
OAUTH2_POCKETID_CLIENT_ID
OAUTH2_POCKETID_CLIENT_SECRET
OAUTH2_POCKETID_ALLOWED_EMAILS
OAUTH2_POCKETID_PLAIN_DOMAIN
OAUTH2_YANDEX_ENABLED
OAUTH2_YANDEX_CLIENT_ID
OAUTH2_YANDEX_CLIENT_SECRET
OAUTH2_YANDEX_ALLOWED_EMAILS
# Branding Settings β Now in Panel UI
BRANDING_LOGO_URL
BRANDING_TITLEAutomatic Migration Process:
# Migration happens automatically during update
remnawave update
# What happens:
# 1. Detects deprecated variables in .env
# 2. Creates backup: /opt/remnawave/.env.backup.TIMESTAMP
# 3. Removes deprecated variables from .env
# 4. Shows migration summary
# 5. Guides to configure settings in panel UIConfigure in Panel UI:
- Settings β Authentication β Login Methods (OAuth settings)
- Settings β Branding (Logo and title)
Benefits:
- β No more panel restarts for configuration changes
- β Real-time preview of branding changes
- β Secure credential management in UI
- β Cleaner .env file
Configure during installation or via .env:
# Enable Telegram notifications
IS_TELEGRAM_NOTIFICATIONS_ENABLED=true
TELEGRAM_BOT_TOKEN=your_bot_token
# User notifications
TELEGRAM_NOTIFY_USERS_CHAT_ID=your_chat_id
TELEGRAM_NOTIFY_USERS_THREAD_ID=thread_id # Optional
# Node notifications
TELEGRAM_NOTIFY_NODES_CHAT_ID=your_chat_id
TELEGRAM_NOTIFY_NODES_THREAD_ID=thread_id # OptionalFeatures:
- Backup completion notifications
- System status alerts
- Large file delivery (>50MB) with chunked uploads
- Thread support for organized group chats
/opt/remnawave/ # Default installation
βββ .env # Main configuration
βββ .env.subscription # Subscription page config
βββ docker-compose.yml # Container orchestration
βββ app-config.json # Optional app configuration
βββ backup-config.json # Backup system config
βββ backup-scheduler.sh # Automated backup script
βββ backups/ # Backup storage
β βββ remnawave_full_*.tar.gz # Full system backups
β βββ remnawave_db_*.sql.gz # Database backups
β βββ remnawave_scheduled_* # Automated backups
βββ logs/ # System logs
βββ backup.log # Backup operations log
βββ panel.log # Panel operations log
/usr/local/bin/remnawave # Management script
A production-ready Bash script to install and manage RemnaNode - high-performance proxy nodes with advanced Xray-core integration. Designed for seamless connection to Remnawave Panel with enterprise-grade features.
ποΈ Complete Node Management
- Full CLI interface:
install,up,down,restart,status,logs,update,uninstall - Interactive main menu with adaptive terminal sizing
- Automatic port conflict detection and resolution
- Real-time log monitoring for Xray-core
β‘ Advanced Xray-core Integration
- Automatic latest version detection and installation
- Interactive version selection with pre-release support
- Custom Xray-core binary management
- Real-time log streaming (
xray_log_out,xray_log_err)
π§ Production Features
- Log rotation with configurable retention
- Multi-architecture support (x86_64, ARM64, ARM32, MIPS)
- Development mode support with
--devflag - Comprehensive system requirements validation
- Universal configuration support:
.envfiles and inline docker-compose variables - Automatic environment variable migration with backup support
# Install RemnaNode
bash <(curl -Ls https://github.com/DigneZzZ/remnawave-scripts/raw/main/remnanode.sh) @ install
# Install with custom name
bash <(curl -Ls https://github.com/DigneZzZ/remnawave-scripts/raw/main/remnanode.sh) @ install --name remnanode
# Install development version
bash <(curl -Ls https://github.com/DigneZzZ/remnawave-scripts/raw/main/remnanode.sh) @ install --dev --name node-dev| Command | Description | Usage |
|---|---|---|
install |
Install RemnaNode | remnanode install [--dev] [--name NAME] |
update |
Update script and container | remnanode update |
uninstall |
Remove node and data | remnanode uninstall |
up |
Start node services | remnanode up |
down |
Stop node services | remnanode down |
restart |
Restart node | remnanode restart |
status |
Show service status | remnanode status |
logs |
View container logs | remnanode logs |
core-update |
Update Xray-core binary | remnanode core-update |
edit |
Edit docker-compose.yml | remnanode edit |
edit-env |
Edit .env file | remnanode edit-env |
setup-logs |
Configure log rotation | remnanode setup-logs |
xray_log_out |
Monitor Xray output logs | remnanode xray_log_out |
xray_log_err |
Monitor Xray error logs | remnanode xray_log_err |
Automatic Installation
# Install latest Xray-core during setup
remnanode install # Automatically offers latest Xray-core
# Update to specific version
remnanode core-update # Interactive version selectionReal-time Monitoring
# Monitor Xray output in real-time
remnanode xray_log_out
# Monitor Xray errors
remnanode xray_log_err
# Standard container logs
remnanode logsEnvironment Variable Migration
Starting with RemnaNode v2.2.2+, environment variables have been renamed for better clarity:
APP_PORTβNODE_PORTSSL_CERTβSECRET_KEY
Universal Configuration Support:
The script now supports both .env files and inline environment variables in docker-compose.yml:
# Option 1: Using .env file (Recommended)
# /opt/remnanode/.env
NODE_PORT=3000
SECRET_KEY=your_secret_key
# Option 2: Inline in docker-compose.yml (Also supported)
# docker-compose.yml
services:
remnanode:
environment:
- NODE_PORT=3000
- SECRET_KEY=your_secret_keyAutomatic Migration Process:
# Migration happens automatically during update
remnanode update
# What happens during migration:
# 1. Auto-detects configuration type (.env or inline)
# 2. Creates backup with timestamp
# 3. Migrates old variables:
# - APP_PORT β NODE_PORT
# - SSL_CERT β SECRET_KEY
# 4. For inline variables: Offers migration to .env (more secure)
# 5. Applies changes with automatic restartNew Smart Edit Command:
# Automatically detects configuration and opens appropriate editor
remnanode edit-env
# Behavior:
# - .env exists β Opens .env file
# - Inline variables β Offers migration to .env
# - No config β Creates new .env templateBackward Compatibility:
- β
Old variables (
APP_PORT,SSL_CERT) work via fallback - β Both .env and inline configurations supported
- β Seamless migration with zero downtime
- β No manual intervention required
Log Rotation Setup
# Configure automatic log rotation
remnanode setup-logs
# Rotation settings:
# - Max size: 50MB per log file
# - Keep 5 rotated files
# - Compress old logs
# - Safe truncation without stopping servicesSecurity Hardening
# Recommended UFW configuration
sudo ufw allow from PANEL_IP to any port NODE_PORT
sudo ufw enable
# The script automatically:
# - Detects occupied ports
# - Suggests available alternatives
# - Validates port ranges/opt/remnanode/ # Node installation
βββ .env # Environment configuration
βββ docker-compose.yml # Container orchestration
/var/lib/remnanode/ # Data directory
βββ xray # Xray-core binary (if installed)
βββ access.log # Xray access logs
βββ error.log # Xray error logs
βββ *.log # Additional Xray logs
/usr/local/bin/remnanode # Management script
/etc/logrotate.d/remnanode # Log rotation config
Supported Platforms:
- x86_64 (Intel/AMD 64-bit)
- ARM64 (ARMv8 64-bit)
- ARM32 (ARMv7 32-bit)
- MIPS (MIPS architecture)
Automatic Detection: The script automatically detects your system architecture and downloads the appropriate Xray-core binary.
A specialized Bash script for deploying Caddy as a Reality traffic masking solution. Provides legitimate HTTPS traffic camouflage for Xray Reality configurations with professional web templates.
π Traffic Masking
- Professional website templates for traffic camouflage
- Automatic HTTPS certificate management
- Configurable ports for Reality integration
- DNS validation with propagation checking
π Template System
- Multiple pre-built website templates
- Automatic template downloading and installation
- Fallback HTML creation if download fails
- Professional appearance for traffic masking
π§ Reality Integration
- Port configuration for Xray Reality compatibility
- Automatic redirects and traffic handling
- Internal certificate management
- DNS validation for proper setup
# Install Caddy Selfsteal
bash <(curl -Ls https://github.com/DigneZzZ/remnawave-scripts/raw/main/selfsteal.sh) @ install| Command | Description | Usage |
|---|---|---|
install |
Install Caddy Selfsteal | selfsteal install |
up |
Start Caddy services | selfsteal up |
down |
Stop Caddy services | selfsteal down |
restart |
Restart Caddy | selfsteal restart |
status |
Show service status | selfsteal status |
logs |
View Caddy logs | selfsteal logs |
template |
Manage website templates | selfsteal template |
edit |
Edit Caddyfile | selfsteal edit |
uninstall |
Remove Caddy setup | selfsteal uninstall |
guide |
Show Reality integration guide | selfsteal guide |
update |
Update script | selfsteal update |
Available Templates:
- 10gag - Social media style template
- converter - File converter service template
- downloader - Download service template
- filecloud - Cloud storage template
- games-site - Gaming website template
- modmanager - Mod management template
- speedtest - Speed test service template
- YouTube - Video platform template
Template Operations:
# List available templates
selfsteal template list
# Install specific template
selfsteal template install converter
# Show current template info
selfsteal template info
# Download template manually
selfsteal template download speedtestConfiguration for Xray Reality:
{
"realitySettings": {
"dest": "127.0.0.1:9443",
"serverNames": ["your-domain.com"]
}
}Automatic Checks:
- Domain format validation
- A record DNS resolution
- AAAA record (IPv6) checking
- CNAME record detection
- DNS propagation across multiple servers (8.8.8.8, 1.1.1.1, etc.)
- Port availability verification
Setup Requirements:
- Domain must point to server IP
- Port 443 free for Xray Reality
- Port 80 available for HTTP redirects
- Proper DNS propagation
/opt/caddy/ # Caddy installation
βββ .env # Environment configuration
βββ docker-compose.yml # Container orchestration
βββ Caddyfile # Caddy configuration
βββ logs/ # Caddy logs
βββ html/ # Website content
βββ index.html # Main page
βββ 404.html # Error page
βββ assets/ # Template assets
βββ style.css # Styling
βββ script.js # JavaScript
βββ images/ # Images and icons
/usr/local/bin/selfsteal # Management script
Linux Distributions:
- Ubuntu 18.04+ (LTS recommended)
- Debian 10+ (Buster and newer)
- CentOS 7+ / AlmaLinux 8+
- Amazon Linux 2
- Fedora 32+
- Arch Linux (rolling)
- openSUSE Leap 15+
Minimum Requirements:
- CPU: 1 core (2+ cores recommended for production)
- RAM: 512MB (1GB+ recommended)
- Storage: 2GB free space (5GB+ for backups)
- Network: Stable internet connection
Recommended for Production:
- CPU: 2+ cores
- RAM: 2GB+
- Storage: 10GB+ SSD storage
- Network: 100Mbps+ connection
Supported Architectures:
- x86_64 (Intel/AMD 64-bit) - Primary support
- ARM64 (ARMv8 64-bit) - Full support
- ARM32 (ARMv7 32-bit) - Basic support
- MIPS - Limited support
Automatically Installed:
- Docker Engine (latest stable)
- Docker Compose V2
- curl / wget
- openssl
- jq (for JSON processing)
- unzip / tar / gzip
Text Editors (Auto-detected):
- nano (default)
- vim / vi
- micro
- emacs
Network Security:
- All services bind to
127.0.0.1by default - Automatic port conflict detection
- UFW firewall configuration guidance
- SSL/TLS certificate management
Data Protection:
- Database credentials auto-generation
- JWT secrets randomization
- Environment variable validation
- Secure backup encryption support
Access Control:
- Telegram OAuth integration
- Admin ID validation
- Rate limiting support
- Webhook signature verification
Recommended Security Setup:
# Configure UFW firewall
sudo ufw default deny incoming
sudo ufw default allow outgoing
sudo ufw allow ssh
sudo ufw allow from trusted_ip to any port panel_port
sudo ufw enable
# Regular security updates
sudo apt update && sudo apt upgrade -y # Ubuntu/Debian
sudo yum update -y # CentOS/AlmaLinux
# Monitor logs
remnawave logs --follow
tail -f /var/log/auth.logEnvironment Security:
- Regular backup verification
- Database access auditing
- Container image scanning
- Dependency vulnerability monitoring
Built-in Monitoring:
# Service status
remnawave status
remnanode status
selfsteal status
# Resource usage
docker stats
docker system df
# Log monitoring
remnawave logs --follow
remnanode logs
selfsteal logsMetrics Integration:
- Prometheus metrics endpoint (
/api/metrics) - Custom metrics collection
- Performance monitoring
- Resource usage tracking
Log Locations:
# Panel logs
/opt/remnawave/logs/
βββ backup.log # Backup operations
βββ panel.log # Panel operations
βββ docker-compose.log # Container logs
# Node logs
/var/lib/remnanode/
βββ access.log # Xray access logs
βββ error.log # Xray error logs
βββ node.log # Node operations
# Caddy logs
/opt/caddy/logs/
βββ access.log # HTTP access
βββ error.log # HTTP errors
βββ caddy.log # Caddy operations
Log Rotation:
- Automatic rotation (50MB max per file)
- Compression of old logs
- Configurable retention (5 files default)
- Safe truncation without service interruption
We welcome contributions to improve the Remnawave Scripts! Here's how you can help:
- Check existing issues before creating new ones
- Provide detailed information:
- OS and version
- Script version
- Error messages
- Steps to reproduce
- Describe the use case clearly
- Explain the expected behavior
- Consider backward compatibility
- Provide implementation ideas if possible
- Fork the repository
- Create a feature branch
- Make your changes
- Test thoroughly
- Update documentation
- Submit pull request
Development Guidelines:
- Follow existing code style
- Add comments for complex logic
- Test on multiple distributions
- Update README if needed
This project is licensed under the MIT License - see the LICENSE file for details.
- β Commercial use allowed
- β Modification allowed
- β Distribution allowed
- β Private use allowed
- β No liability for authors
- β No warranty provided
π GIG.ovh
- Website: https://gig.ovh
- FOCUS: Next-Gen forum comminity with AI ChatBot, VIP Groups and other..
β If you find this project helpful, please consider giving it a star!
π Report Bug β’ Request Feature β’ Contribute
