Slackpass is a virtual machine manager for Linux distributions, inspired by Multipass. It creates and manages Linux virtual machines using KVM/QEMU with a simple command-line interface.
- Multiple Linux Distributions: Support for Slackware, Debian, Fedora, AlmaLinux, Rocky Linux, CentOS, Gentoo, and openSUSE
- KVM/QEMU Backend: Uses KVM virtualization with QEMU for high performance
- SSH Integration: Automatic SSH access to virtual machines
- Cloud Images: Downloads and uses official cloud images
- Simple CLI: Easy-to-use command-line interface similar to Multipass
- Debian: bookworm (12), bullseye (11)
- Fedora: 39, 38, 37
- AlmaLinux: 9, 8
- Rocky Linux: 9, 8
- CentOS: Stream 9, Stream 8
- openSUSE: Tumbleweed, Leap 15.5
- Gentoo: Latest
- Slackware: 15.0, 14.2
- Linux operating system
- KVM virtualization support
- QEMU installed (
qemu-system-x86_64,qemu-img) - SSH client
- Go 1.21+ (for building from source)
sudo apt update
sudo apt install qemu-kvm qemu-utils libvirt-daemon-system libvirt-clients bridge-utils
sudo usermod -aG kvm,libvirt $USERsudo dnf install qemu-kvm qemu-img libvirt libvirt-daemon-config-network libvirt-daemon-kvm
sudo usermod -aG kvm,libvirt $USERgit clone https://github.com/slackpass/slackpass.git
cd slackpass
go build -o slackpass
sudo mv slackpass /usr/local/bin/-
Launch a virtual machine:
slackpass launch debian
-
List running instances:
slackpass list
-
Open a shell session:
slackpass shell butterfly-effect
-
Execute a command:
slackpass exec butterfly-effect -- sudo apt update -
Stop and delete an instance:
slackpass stop butterfly-effect slackpass delete butterfly-effect
slackpass launch [image] [name]- Create and start a new virtual machineslackpass list- List all virtual machine instancesslackpass shell [name]- Open a shell session to a virtual machineslackpass exec [name] -- [command]- Execute a command on a virtual machineslackpass info [name]- Display detailed information about instancesslackpass start [name...]- Start virtual machine instancesslackpass stop [name...]- Stop virtual machine instancesslackpass delete [name...]- Delete virtual machine instances
slackpass find [image-name]- Display available images to launch
# Launch different distributions
slackpass launch debian:bookworm mydebian
slackpass launch fedora:39 myfedora --cpus 2 --memory 2G
slackpass launch almalinux:9 myalma --disk 20G
# Find available images
slackpass find
slackpass find debian
# Manage instances
slackpass list
slackpass info mydebian
slackpass shell mydebian
slackpass exec mydebian -- ls -la /home
# Stop and clean up
slackpass stop mydebian myfedora
slackpass delete mydebian --purgeSlackpass stores its configuration and data in ~/.slackpass/:
~/.slackpass/instances/- Virtual machine instances~/.slackpass/images/- Downloaded cloud images~/.slackpass/keys/- SSH keys
Slackpass is built with a modular architecture:
- CLI Layer: Cobra-based command-line interface
- VM Manager: High-level virtual machine operations
- KVM Client: Low-level QEMU/KVM integration
- SSH Client: SSH connection and command execution
- Image Manager: Cloud image discovery and management
- Configuration: Application settings and defaults
go mod download
go build -o slackpassgo test ./...slackpass/
├── main.go # Application entry point
├── cmd/ # CLI commands
│ ├── root.go # Root command and configuration
│ ├── launch.go # Launch command
│ ├── list.go # List command
│ ├── shell.go # Shell command
│ ├── exec.go # Exec command
│ ├── info.go # Info command
│ ├── start.go # Start/Stop commands
│ ├── delete.go # Delete command
│ └── find.go # Find command
├── internal/ # Internal packages
│ ├── vm/ # Virtual machine management
│ ├── kvm/ # KVM/QEMU integration
│ ├── ssh/ # SSH client
│ ├── images/ # Image management
│ └── config/ # Configuration
└── go.mod # Go module definition
Contributions are welcome! Please feel free to submit a Pull Request.
This project is licensed under the MIT License - see the LICENSE file for details.