Skip to main content

WASM - Web App System Management

WASM Logo

OBS Build Status PyPI Version Python Version License GitHub Stars PyPI Downloads


Overview

WASM is a command-line tool for deploying and managing web applications on Linux servers. It automates the deployment workflow from repository cloning through production serving, handling Nginx/Apache configuration, SSL certificates, systemd services, and application builds.

Core Functionality

  • Deploy Next.js, Node.js, Vite, Python, and static applications
  • Configure Nginx and Apache virtual hosts
  • Manage SSL certificates via Let's Encrypt/Certbot
  • Create and control systemd services
  • Database management (MySQL, PostgreSQL, Redis, MongoDB)
  • Backup and rollback system
  • Control panel (optional)
  • Resource and service observability

Installation

Ubuntu/Debian (Recommended)

# Add GPG key
curl -fsSL https://download.opensuse.org/repositories/home:/Perkybeet/xUbuntu_26.04/Release.key | \
  gpg --dearmor | sudo tee /usr/share/keyrings/wasm.gpg > /dev/null

# Add repository
echo 'deb [signed-by=/usr/share/keyrings/wasm.gpg] https://download.opensuse.org/repositories/home:/Perkybeet/xUbuntu_26.04/ /' | \
  sudo tee /etc/apt/sources.list.d/wasm.list

# Install
sudo apt update
sudo apt install wasm

Supported versions:

  • Ubuntu 26.04 LTS (Resolute Raccoon, Python 3.14)
  • Ubuntu 24.04 LTS (Noble Numbat)
  • Ubuntu 22.04 LTS (Jammy Jellyfish)
  • Debian 12 (Bookworm) and 13 (Trixie)

Fedora

sudo dnf config-manager --add-repo \
  https://download.opensuse.org/repositories/home:/Perkybeet/Fedora_42/home:Perkybeet.repo
sudo dnf install wasm-cli

openSUSE

# Tumbleweed
sudo zypper ar -f \
  https://download.opensuse.org/repositories/home:/Perkybeet/openSUSE_Tumbleweed/ \
  home_Perkybeet
sudo zypper install wasm-cli

# Leap 15.6
sudo zypper ar -f \
  https://download.opensuse.org/repositories/home:/Perkybeet/openSUSE_Leap_15.6/ \
  home_Perkybeet
sudo zypper install wasm-cli

PyPI

pip install wasm-cli

From Source

git clone https://github.com/Perkybeet/wasm.git
cd wasm
pip install -e .

Quick Start

Deploy a Next.js Application

wasm create \
  --domain myapp.example.com \
  --source git@github.com:user/my-nextjs-app.git \
  --type nextjs \
  --port 3000

Short syntax:

wasm create -d myapp.example.com -s git@github.com:user/app.git -t nextjs -p 3000

Interactive Mode

Run wasm without arguments to enter interactive mode:

wasm

The interactive wizard will guide you through:

  1. Application type selection
  2. Domain configuration
  3. Source repository
  4. Port assignment
  5. SSL certificate setup

Usage

Application Management

# Deploy application
wasm create -d example.com -s git@github.com:user/repo.git -t nextjs

# List deployed applications
wasm list

# View application status
wasm status example.com

# Restart application
wasm restart example.com

# Update application (git pull + rebuild)
wasm update example.com

# Remove application
wasm delete example.com

# View application logs
wasm logs example.com --follow

Site Configuration

# Create Nginx/Apache site
wasm site create -d example.com -w nginx

# List all sites
wasm site list

# Enable or disable site
wasm site enable example.com
wasm site disable example.com

# Delete site
wasm site delete example.com

SSL Certificates

# Obtain Let's Encrypt certificate
wasm cert create -d example.com

# List certificates
wasm cert list

# Renew certificates
wasm cert renew

# View certificate details
wasm cert info example.com

Service Management

# Create systemd service
wasm service create --name myservice --command "/usr/bin/myapp" --user www-data

# Control services
wasm service start myservice
wasm service stop myservice
wasm service restart myservice

# View service status and logs
wasm service status myservice
wasm service logs myservice --follow

# Delete service
wasm service delete myservice

Database Management

# Install database engine
wasm db install mysql

# Create database
wasm db create mydb --engine mysql

# List databases
wasm db list --engine mysql

# Backup database
wasm db backup mydb --engine mysql --output backup.sql.gz

# Restore database
wasm db restore mydb backup.sql.gz --engine mysql

Backup and Rollback

# Create backup
wasm backup create example.com -m "Pre-deployment backup"

# List backups
wasm backup list example.com

# Restore from backup
wasm backup restore BACKUP_ID

# Quick rollback to last backup
wasm rollback example.com

Supported Application Types

Type Framework Auto-Detection
nextjs Next.js next.config.js, next.config.mjs
nodejs Express, Fastify, Koa package.json with start script
vite React, Vue, Svelte (Vite) vite.config.js, vite.config.ts
python Django, Flask, FastAPI requirements.txt, pyproject.toml
static HTML/CSS/JS index.html

Deployment Workflow

For each application type, WASM executes:

  1. Clone repository to /var/www/apps/wasm-<app-name>/
  2. Install dependencies (npm, pip, etc.)
  3. Build application (if applicable)
  4. Create systemd service
  5. Configure Nginx/Apache reverse proxy
  6. Obtain SSL certificate (optional)
  7. Start service and verify status

Configuration

Global Configuration

Configuration file: /etc/wasm/config.yaml

# Web server preference
webserver: nginx

# Application directory
apps_directory: /var/www/apps

# Service user
service_user: www-data

# SSL configuration
ssl:
  enabled: true
  provider: certbot
  email: admin@example.com

# Logging
logging:
  level: info
  file: /var/log/wasm/wasm.log

# Node.js settings
nodejs:
  default_version: 20
  use_nvm: false

# Python settings
python:
  default_version: "3.11"
  use_venv: true

Per-Application Configuration

Create .wasm.yaml in your project root:

type: nextjs
port: 3000
build_command: npm run build
start_command: npm run start
env_vars:
  NODE_ENV: production
health_check:
  path: /api/health
  timeout: 30

Command Reference

Application Commands

wasm create [options]          Deploy new application
wasm list                       List deployed applications
wasm status <domain>            Show application status
wasm restart <domain>           Restart application
wasm stop <domain>              Stop application
wasm start <domain>             Start application
wasm update <domain>            Update application (git pull + rebuild)
wasm delete <domain>            Remove application
wasm logs <domain> [options]    View application logs

Site Commands

wasm site create <domain>       Create site configuration
wasm site list                  List all sites
wasm site enable <domain>       Enable site
wasm site disable <domain>      Disable site
wasm site delete <domain>       Delete site
wasm site show <domain>         Display site configuration

Service Commands

wasm service create [options]   Create systemd service
wasm service list               List managed services
wasm service status <name>      Show service status
wasm service start <name>       Start service
wasm service stop <name>        Stop service
wasm service restart <name>     Restart service
wasm service logs <name>        View service logs
wasm service delete <name>      Delete service

Certificate Commands

wasm cert create <domain>       Obtain SSL certificate
wasm cert list                  List certificates
wasm cert info <domain>         Show certificate details
wasm cert renew [domain]        Renew certificates
wasm cert revoke <domain>       Revoke certificate

Database Commands

wasm db install <engine>        Install database engine
wasm db create <name>           Create database
wasm db drop <name>             Drop database
wasm db list                    List databases
wasm db backup <name>           Backup database
wasm db restore <name> <file>   Restore database
wasm db user-create <username>  Create database user
wasm db grant <user> <db>       Grant privileges

Backup Commands

wasm backup create <domain>     Create backup
wasm backup list [domain]       List backups
wasm backup restore <id>        Restore from backup
wasm backup delete <id>         Delete backup
wasm backup verify <id>         Verify backup integrity
wasm rollback <domain> [id]     Quick rollback

Control Panel

An optional panel for the machine WASM runs on. It is server-rendered HTML updated by htmx, with no build step, no Node and no third-party CDN, so it works on a server with no route to the internet.

Installation

pip install wasm-cli[web]

Start it

# Localhost only. This is the default and the safe one.
wasm web start

# Reachable from the network. TLS is required, because the panel's token is
# root on this machine.
wasm web start --host 0.0.0.0 --require-https --tls-cert cert.pem --tls-key key.pem

# Behind a TLS-terminating reverse proxy: declare it, so the panel trusts its
# forwarded headers and marks the session cookie Secure.
wasm web start --trusted-proxy 127.0.0.1

Print the access token with wasm web token.

What it does

  • Overview of the machine: load, memory, disk and the state of every managed service
  • Applications, services, sites and databases, with their live state
  • Live logs streamed from journald into a docked terminal
  • A JSON API under /api for automation, authenticated with the same token

Sessions use an HttpOnly cookie with CSRF protection; the API also accepts Authorization: Bearer for scripts. Every privileged action is written to an append-only audit log.

Not yet in the panel

Certificate issuance, backup and restore, scheduled jobs and settings currently have API endpoints but no screen. Use the CLI for those.


System Requirements

  • Operating System: Ubuntu 22.04+, Debian 12+, Fedora 40+, openSUSE Leap 15.6+
  • Python: 3.10 to 3.14
  • Privileges: root. WASM writes to /etc, /var and systemd, so it checks for root on the commands that touch the system rather than escalating per call.

Optional Dependencies

  • nginx or apache2 (web server)
  • certbot (SSL certificates)
  • git (repository cloning)
  • nodejs/npm (for Node.js applications)
  • python3-venv (for Python applications)
  • mysql-server or postgresql (database support)

WASM will check for missing dependencies and prompt installation when needed.


Directory Structure

/var/www/apps/
├── example-com/              # The application, deployed in place
│   └── .env                  # Environment variables, mode 0600
└── another-app/
    └── ...

/var/lib/wasm/wasm.db         # What WASM knows about this machine, mode 0600
/etc/wasm/config.yaml         # Configuration, mode 0600 in a 0700 directory
/var/backups/wasm/            # Backup archives, each self-contained

Rolling back restores from a backup rather than switching a symlink between releases; see wasm backup list and wasm rollback.


Development

# Clone repository
git clone https://github.com/Perkybeet/wasm.git
cd wasm

# Create virtual environment
python -m venv venv
source venv/bin/activate

# Install development dependencies
pip install -e ".[dev]"

# Run tests
pytest

# Run linters
black src/
isort src/
ruff check src/

License

This project is licensed under the WASM Non-Commercial Source-Available License (WASM-NCSAL) Version 1.0.

Free Usage

You may use WASM free of charge for:

  • Personal projects
  • Educational purposes
  • Research and development
  • Non-commercial use

Commercial Usage

Commercial use requires a license. This includes:

  • Use within commercial organizations
  • Providing paid services using WASM
  • Reducing operational costs in business environments
  • Any revenue-generating use case

Obtain Commercial License

For commercial licensing inquiries:

Read full license terms


Acknowledgments


Support


Developed by Bitbeet

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wasm_cli-1.5.0.tar.gz (4.9 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

wasm_cli-1.5.0-py3-none-any.whl (2.5 MB view details)

Uploaded Python 3

File details

Details for the file wasm_cli-1.5.0.tar.gz.

File metadata

  • Download URL: wasm_cli-1.5.0.tar.gz
  • Upload date:
  • Size: 4.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for wasm_cli-1.5.0.tar.gz
Algorithm Hash digest
SHA256 46620fd91e7556fcf5081d245329bbc03d610e8ddbe092865841af2e8284f3bc
MD5 6326c03f30a0770f262c301a4c0f5c62
BLAKE2b-256 f34c8cc02dce77145b9c614bea8391927e7f570817c76c4ae057d0dbb4846564

See more details on using hashes here.

Provenance

The following attestation bundles were made for wasm_cli-1.5.0.tar.gz:

Publisher: release.yml on Perkybeet/wasm

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file wasm_cli-1.5.0-py3-none-any.whl.

File metadata

  • Download URL: wasm_cli-1.5.0-py3-none-any.whl
  • Upload date:
  • Size: 2.5 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for wasm_cli-1.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0568d037db9d196959c9df9b36278e838662debeda30601a30b3a5e1d7280955
MD5 e6f352f0a7b594130fef6d4e967c326a
BLAKE2b-256 02925150b281341e9e33f51e6cce5c2b68360230ec7dfbb796d10877123e3cce

See more details on using hashes here.

Provenance

The following attestation bundles were made for wasm_cli-1.5.0-py3-none-any.whl:

Publisher: release.yml on Perkybeet/wasm

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

1.6.1

2 files

1.6.0

2 files

1.5.1

2 files

This release

1.5.0 This release

2 files

1.2.1

2 files

1.2.0

2 files

1.1.0

2 files

1.0.3

2 files

1.0.2

2 files

1.0.1

2 files

1.0.0

2 files

0.15.8

2 files

0.15.7

2 files

0.15.6

2 files

0.15.5

2 files

0.15.4

2 files

0.15.3

2 files

0.15.2

2 files

0.15.1

2 files

0.15.0

2 files

0.14.4

2 files

0.14.3

2 files

0.14.2

2 files

0.14.1

2 files

0.14.0

2 files

0.13.16

2 files

0.13.15

2 files

0.13.14

2 files

0.13.13

2 files

0.13.12

2 files

0.13.11

2 files

0.13.10

2 files

0.13.9

2 files

0.13.8

2 files

0.13.7

2 files

0.13.6

2 files

0.13.5

2 files

0.13.4

2 files

0.13.3

2 files

0.13.2

2 files

0.13.1

2 files

0.13.0

2 files

0.12.0

2 files

0.11.4

2 files

0.11.3

2 files

0.11.2

2 files

0.11.1

2 files

0.11.0

2 files

0.10.5

2 files

0.10.4

2 files

0.10.3

2 files

0.10.2

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page