Integrate Particle-OS tools into simple-cli
Some checks failed
Build Simple CLI / build (push) Failing after 1s

- Add apt-ostree, deb-bootupd, and bootc packages to tools/
- Update Containerfile to install Particle-OS tools with dependencies
- Add tool verification script and updated welcome message
- Update justfile with new build and test recipes
- Add comprehensive tool testing and bootable image generation
- Successfully integrate 2/3 tools (apt-ostree and bootupd working)
- Note: bootc package contains only documentation, not binary

Ready for bootable image generation and QEMU testing!
This commit is contained in:
joe 2025-08-15 07:56:10 -07:00
parent 6aa6d32e1e
commit 9e9d4ea8d2
19 changed files with 1603 additions and 130 deletions

216
README.md
View file

@ -1,95 +1,176 @@
# Simple CLI
# Simple CLI - Particle-OS Development System
A simple, CLI-focused Debian-based particle-os system built on Universal Blue's framework. Simple CLI provides a minimal, immutable Linux distribution optimized for command-line usage and server workloads.
Simple CLI is a Debian-based Particle-OS system focused on providing a clean, CLI-oriented development environment with container-based development tools.
## Features
- **Immutable Filesystem**: Built on OSTree for reliable, atomic updates
- **Container-Native**: Built as a container image, deployed with bootc
- **Minimal Footprint**: Focused on essential CLI tools and system utilities
- **Modern Boot**: Uses bootupd for modern bootloader management
- **Debian Base**: Built on Debian Trixie for stability and package availability
- **Base System**: Debian Trixie with OSTree
- **Container Runtime**: Podman with full container support
- **Development Tools**: Both Toolbox and Distrobox for development environments
- **Build System**: Just-based automation with comprehensive recipes
- **Immutable Design**: Atomic updates with rollback capability
## Quick Start
## Development Environments
### Building the Image
Simple CLI provides two powerful development environment tools:
### 1. Toolbox (Official Debian Package)
Toolbox is the official container-based development environment tool, tightly integrated with the system.
#### Quick Start
```bash
# Create a development environment
toolbox create dev
# Enter the development environment
toolbox enter dev
# Install development tools
apt update
apt install gcc make git python3-pip
# Work on projects without affecting the immutable host
```
#### Features
- **Native Debian integration** - Uses Debian Trixie containers
- **Host filesystem access** - Full access to your home directory
- **Package management** - Use APT to install any tools
- **System integration** - Access to host network, USB devices, display
### 2. Distrobox (Community Alternative)
Distrobox provides additional flexibility and cross-distribution support.
#### Quick Start
```bash
# Create a development environment
distrobox create dev --image debian:trixie
# Enter the development environment
distrobox enter dev
# Install development tools
apt update
apt install build-essential git python3-pip
# Work on projects with full flexibility
```
#### Features
- **Cross-distribution support** - Can use Ubuntu, Fedora, or other images
- **Advanced container management** - More flexible than Toolbox
- **Multiple backends** - Supports both Docker and Podman
- **Custom configurations** - Highly configurable for specific needs
## Using Just Commands
Simple CLI includes comprehensive Just-based automation:
```bash
# Clone the repository
git clone https://github.com/your-username/simple-cli.git
cd simple-cli
# Setup development environment
just setup-dev
# Create development environments
just create-dev-toolbox # Create Toolbox environment
just create-dev-distrobox # Create Distrobox environment
# Enter environments
just dev-toolbox # Enter Toolbox environment
just dev-distrobox # Enter Distrobox environment
# Test functionality
just test-toolbox # Test Toolbox
just test-distrobox # Test Distrobox
# List all environments
just list-envs # Show all development environments
# Clean up
just cleanup-envs # Remove all development environments
```
## When to Use Which Tool?
### Use Toolbox When:
- **Native Debian development** - Working with Debian-specific tools
- **System integration** - Need tight integration with host system
- **Official support** - Prefer officially supported tools
- **Simple workflows** - Basic development environment needs
### Use Distrobox When:
- **Cross-distribution** - Need tools from other distributions
- **Custom configurations** - Require specific container setups
- **Advanced workflows** - Complex development environment needs
- **Flexibility** - Want more control over container configuration
## Configuration Files
### Toolbox Configuration
- **`/etc/containers/toolbox.conf`** - Main Toolbox configuration
- **`/etc/profile.d/toolbox.sh`** - Shell integration and welcome messages
- **`/usr/lib/tmpfiles.d/toolbox.conf`** - Systemd integration
### Distrobox Configuration
- **`/etc/distrobox/docker.ini`** - Docker backend configuration
- **`/etc/distrobox/podman.ini`** - Podman backend configuration
## Building and Testing
```bash
# Build the container image
just build
# Test the image
just test
# Generate bootable images
# Generate bootable image
just generate-bootable
# Full pipeline
just pipeline
```
### Using the System
## System Requirements
```bash
# Show system information
ujust info
- **Container Runtime**: Podman or Docker
- **Storage**: 10GB+ for development environments
- **Memory**: 4GB+ RAM recommended
- **Architecture**: x86_64 (amd64)
# Check OSTree status
ujust ostree-status
## Troubleshooting
# Update the system
ujust update
### Common Issues
# View system services
ujust services
```
1. **Permission Denied**: Ensure your user is in the appropriate groups
```bash
sudo usermod -a -G podman $USER
newgrp podman
```
## Architecture
2. **Container Creation Fails**: Check container runtime status
```bash
podman system info
systemctl status podman.socket
```
Simple CLI follows the particle-os architecture:
3. **Network Issues**: Verify host networking
```bash
ip addr show
toolbox enter dev -- ip addr show
```
1. **Container Image**: The OS is built as a container image using the Containerfile
2. **OSTree Deployment**: Container images are converted to OSTree commits
3. **Bootable Images**: bootc-image-builder creates bootable disk images
4. **System Management**: bootupd handles bootloader updates and management
### Getting Help
## Directory Structure
```
simple-cli/
├── Containerfile # Main container build definition
├── recipe.yml # particle-os recipe configuration
├── justfile # Build automation commands
├── config/ # System configuration files
├── usr/ # User space configurations
├── etc/ # System-wide configuration
├── build_files/ # Build-time specifications
└── .github/workflows/ # CI/CD automation
```
## Development
### Prerequisites
- Podman or Docker
- Just command runner
- bootc-image-builder (for bootable image generation)
### Setup Development Environment
```bash
just setup-dev
```
### Available Commands
```bash
just --list
```
- **Toolbox**: [containertoolbx.org](https://containertoolbox.org/)
- **Distrobox**: [github.com/89luca89/distrobox](https://github.com/89luca89/distrobox)
- **Particle-OS**: Project documentation and community
## Contributing
Simple CLI is part of the Particle-OS project. Contributions are welcome!
1. Fork the repository
2. Create a feature branch
3. Make your changes
@ -98,11 +179,4 @@ just --list
## License
This project is licensed under the Apache 2.0 License - see the LICENSE file for details.
## Acknowledgments
- Built on [particle-os](https://github.com/particle-os) framework
- Inspired by [Aurora](https://github.com/particle-os/aurora) and other particle-os projects
- Uses [bootc](https://github.com/containers/bootc) for container-native boot
- Powered by [OSTree](https://ostreedev.github.io/ostree/) for immutable filesystems
This project is part of Particle-OS and follows the same licensing terms.