This comprehensive guide covers all installation methods and requirements for nself (Nhost Self-hosted CLI), the powerful tool for deploying production-ready backend infrastructure.
nself is compatible with:
The installer now features automatic SSL configuration, enterprise monitoring tools, advanced backup capabilities, and intelligent resource scaling - all with zero-config automation.
The fastest way to install nself is using our automated installer:
curl -fsSL https://raw.githubusercontent.com/acamarata/nself/main/install.sh | bash
This single command will:
~/.nself/bin
The installation script performs these steps:
nself version
to confirm successful installationIf you prefer to install manually or need more control over the process:
Visit the nself releases page and download the appropriate binary for your system:
# Linux x64
wget https://github.com/acamarata/nself/releases/latest/download/nself-linux-x64
# macOS (Intel)
wget https://github.com/acamarata/nself/releases/latest/download/nself-macos-x64
# macOS (Apple Silicon)
wget https://github.com/acamarata/nself/releases/latest/download/nself-macos-arm64
# Windows (WSL2)
wget https://github.com/acamarata/nself/releases/latest/download/nself-windows-x64.exe
# Create nself directory
mkdir -p ~/.nself/bin
# Move and rename binary (Linux/macOS)
mv nself-* ~/.nself/bin/nself
# Make executable
chmod +x ~/.nself/bin/nself
Add nself to your PATH by updating your shell profile:
# For bash
echo 'export PATH="$HOME/.nself/bin:$PATH"' >> ~/.bashrc
# For zsh
echo 'export PATH="$HOME/.nself/bin:$PATH"' >> ~/.zshrc
# For fish
echo 'set -gx PATH $HOME/.nself/bin $PATH' >> ~/.config/fish/config.fish
Reload your shell or run:
source ~/.bashrc # or ~/.zshrc
nself version
You should see output similar to:
nself version 0.3.8
Enterprise-Ready Backend Stack
nself requires Docker and Docker Compose to orchestrate your backend services.
# Update package index
sudo apt-get update
# Install dependencies
sudo apt-get install ca-certificates curl gnupg lsb-release
# Add Docker's GPG key
sudo mkdir -m 0755 -p /etc/apt/keyrings
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
# Set up repository
echo "deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
# Install Docker
sudo apt-get update
sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
# Add user to docker group
sudo usermod -aG docker $USER
# Install Docker
sudo dnf install docker docker-compose
# Start and enable Docker
sudo systemctl start docker
sudo systemctl enable docker
# Add user to docker group
sudo usermod -aG docker $USER
# Using Homebrew
brew install docker docker-compose
# Or download Docker Desktop from https://docker.com
# Check Docker version
docker --version
# Check Docker Compose
docker compose version
# Test Docker (should download and run hello-world)
docker run hello-world
Currently, nself is distributed as a standalone binary. We recommend using the automated installer script or manual binary installation described above.
We're working on official package manager support for APT, YUM/DNF, and Homebrew. For now, please use the direct installation methods above.
After installation, verify nself is working correctly:
# Check version
nself version
# View help
nself --help
# Check available commands
nself help
Create a test project to ensure everything works:
# Create test directory
mkdir nself-test && cd nself-test
# Initialize project
nself init
# Build configuration
nself build
# Check generated files
ls -la
# Clean up
cd .. && rm -rf nself-test
nself stores global configuration in ~/.nself/config.yaml
:
# Default settings
auto_update: true
telemetry: false
default_environment: development
docker_socket: unix:///var/run/docker.sock
# Registry settings
registry:
default: docker.io
mirrors: []
# Update settings
updates:
check_interval: 24h
include_prereleases: false
Configure nself behavior with environment variables:
# Disable auto-updates
export NSELF_AUTO_UPDATE=false
# Custom Docker socket
export DOCKER_HOST=unix:///var/run/docker.sock
# Debug mode
export NSELF_DEBUG=true
# Custom config location
export NSELF_CONFIG_DIR=$HOME/.config/nself
Simply run nself update
to get the latest version. The update system now includes automatic rollback, progress indicators, and version verification.
nself can automatically update itself with the new v0.2.2 update system:
# Update to latest version (v0.2.2+ with visual feedback)
nself update
# The update process will:
# 1. Check current version
# 2. Download latest release
# 3. Create backup of current version
# 4. Install new version
# 5. Verify installation
# 6. Rollback if needed
# Check for updates without installing
nself update --check
# Force update even if on latest version
nself update --force
# Download and replace binary curl -fsSL https://raw.githubusercontent.com/acamarata/nself/main/install.sh | bash
Remove nself and all associated data:
# Stop all running services first
nself down --all
# Remove binary and data
rm -rf ~/.nself
# Remove from PATH (edit your shell profile)
# Remove the line: export PATH="$HOME/.nself/bin:$PATH"
# Fix: Ensure binary is executable
chmod +x ~/.nself/bin/nself
# Fix: Check PATH is correctly set
echo $PATH | grep -o ~/.nself/bin
# Start Docker service
sudo systemctl start docker
# Check Docker status
docker ps
# Check if nself is in PATH
which nself
# Reload shell configuration
source ~/.bashrc
# Test connectivity
curl -I https://github.com
# Use proxy if needed
export HTTP_PROXY=http://proxy.company.com:8080
export HTTPS_PROXY=http://proxy.company.com:8080
Enable debug logging for troubleshooting:
# Enable debug mode
export NSELF_DEBUG=true
# Run command with verbose output
nself --debug version
# Check logs
nself logs --debug
If you encounter issues:
nself logs --debug
When reporting issues, include:
# Generate system info
nself debug system-info
# This outputs:
# - nself version
# - Operating system and version
# - Docker version
# - Available resources
# - Network configuration
Once nself is installed:
Install nself to a custom location:
# Set custom installation directory
export NSELF_INSTALL_DIR=/opt/nself
# Run installer
curl -fsSL https://raw.githubusercontent.com/acamarata/nself/main/install.sh | bash
For environments without internet access:
For enterprise environments with specific requirements:
# Use enterprise registry
export NSELF_REGISTRY=registry.company.com
# Custom CA certificates
export NSELF_CA_BUNDLE=/path/to/ca-bundle.crt
# Install with enterprise settings
curl -fsSL https://raw.githubusercontent.com/acamarata/nself/main/install.sh | bash
The installation is now complete! nself is ready to help you deploy production-ready backend infrastructure with a single command.