____ _ _ _____ _
/ ___|___ _ __ | |_ __ _(_)_ __ ___ _ __ | ____|_ __ ___(_)_ __ ___
| | / _ \| '_ \| __/ _` | | '_ \ / _ \ '__| | _| | '_ \ / __| | '_ \ / _ \
| |__| (_) | | | | || (_| | | | | | __/ | | |___| | | | (__| | | | | __/
\____\___/|_| |_|\__\__,_|_|_| |_|\___|_| |_____|_| |_|\___|_|_| |_|\___|
Deploy Containers in Seconds. Your App, Live on the Web.
An Open-Source Alternative to Google Cloud Run - Built with Rust & Axum
Container Engine is an open-source alternative to Google Cloud Run, built with Rust and the Axum framework. This revolutionary service empowers developers to effortlessly deploy containerized applications to the internet with unprecedented simplicity and speed. By intelligently abstracting away the complexity of Kubernetes infrastructure, Container Engine creates a seamless deployment experience that lets you focus entirely on your code and business logic, not on managing infrastructure.
Unlike proprietary solutions, Container Engine provides a complete User Management System including user registration, authentication, API key management, and deployment management - all while being fully open-source. With Container Engine, the journey from a Docker image to a live, production-ready URL happens with just a single API call—no YAML configurations to write, no kubectl commands to remember, and no infrastructure headaches.
- User Registration & Authentication: Complete user registration and login system with secure password management
- API Key Management: Generate, manage, and revoke API keys for secure access to the platform
- User Dashboard: Comprehensive user interface for managing deployments, viewing usage, and account settings
- Deploy via API: Go from container image to live URL with a single API call, reducing deployment time from hours to seconds.
- Zero Kubernetes Hassle: No need to write YAML or manage
kubectl
. Our engine translates simple REST API calls into complex Kubernetes configurations behind the scenes. - Auto-generated URLs: Every deployment gets a clean, memorable, and instantly accessible URL with automatic HTTPS certificate provisioning and management.
- Scalable by Design: Built on the robust foundation of Kubernetes for reliability and scale, with built-in horizontal scaling capabilities.
- Rust + Axum Backend: High-performance, memory-safe backend built with Rust and the modern Axum web framework
- OpenAPI Documentation: Complete API documentation with Swagger UI integration using utoipa
- Registry Agnostic: Pull public or private images from Docker Hub, Google Container Registry, Amazon ECR, GitHub Container Registry, or any other container registry with support for authentication.
- Environment Variables Management: Securely inject configuration through environment variables without rebuilding images.
- Deployment Monitoring: Real-time logs and performance metrics for all your deployments in one unified dashboard.
- Zero Downtime Updates: Update your applications seamlessly with rolling updates that guarantee availability.
- Automated Setup: Intelligent setup script that checks and installs all required dependencies automatically.
Container Engine is built with modern, high-performance technologies:
- Backend: Rust with Axum framework for maximum performance and memory safety
- Database: PostgreSQL for reliable data persistence
- Container Orchestration: Kubernetes for scalable container management
- Authentication: JWT tokens with bcrypt password hashing
- Monitoring: Prometheus metrics with Grafana dashboards
- Logging: Structured logging with correlation IDs
The Rust + Axum backend provides exceptional performance while ensuring memory safety and preventing common security vulnerabilities.
Container Engine provides a sophisticated yet simple interface between developers and Kubernetes infrastructure. Users interact with the Container Engine REST API or SDK, and our service intelligently translates these high-level deployment requests into the appropriate Kubernetes objects (Deployment, Service, Ingress) on the backend cluster.
The platform handles all the complex networking configuration, ensuring that only the application's HTTP port is exposed to the internet. HTTPS is automatically configured and managed using industry-standard certificates. Upon successful deployment, users receive a public URL to access their application immediately.
+----------------+
| |
| Container |
| Registry |
| |
+--------+-------+
|
| Pull Image
v
+---------------+ API Request +----------+----------+ Manages +----------------+
| | | | | |
| Developer +------------------>+ Container Engine +-------------->+ Kubernetes |
| | | | | Cluster |
+---------------+ API Response +----------+----------+ +--------+-------+
| |
| Create |
v v
+-------------------+ +---------------------+
| | | |
| Public URL |<-------------+ Deployment, |
| user.domain.app | | Service, Ingress |
| | | |
+-------------------+ +---------------------+
The architecture is designed to be cloud-agnostic, meaning Container Engine can orchestrate deployments across multiple cloud providers or on-premise Kubernetes clusters with consistent behavior and performance.
- An account with Container Engine (register via API or web interface)
- An API Key generated from your user dashboard or via the API
- A Docker image available in a container registry
For comprehensive API documentation including authentication, user management, and deployment endpoints, see APIs.md.
For Python developers who want programmatic control:
pip install container-engine-sdk
For web and Node.js applications:
npm install container-engine-sdk
# or
yarn add container-engine-sdk
For command-line enthusiasts:
# Install globally
npm install -g container-engine-cli
# Basic usage
container-engine deploy --image nginx:latest --name my-website
- Sign up for a Container Engine account at [your-domain]
- Generate an API key from your user dashboard
- Prepare your application in a Docker container
- Deploy your container using one of our SDKs or the REST API
- Access your application at the automatically generated URL
Deploy an application using the API:
POST /v1/deployments
Authorization: Bearer <your-api-key>
Content-Type: application/json
{
"appName": "hello-world",
"image": "nginx:latest",
"port": 80,
"envVars": {
"BACKGROUND_COLOR": "blue"
}
}
curl -X POST https://api.[your-domain]/v1/deployments \
-H "Authorization: Bearer <your-api-key>" \
-H "Content-Type: application/json" \
-d '{
"appName": "hello-world",
"image": "nginx:latest",
"port": 80,
"envVars": {"BACKGROUND_COLOR": "blue"}
}'
{
"status": "pending",
"deploymentId": "dpl-a1b2c3d4e5",
"message": "Deployment 'hello-world' is being processed.",
"url": "https://hello-world.decenter.app"
}
from container_engine import ContainerEngineClient
# Initialize client
client = ContainerEngineClient(api_key="your-api-key")
# Deploy a container
deployment = client.deploy(
app_name="hello-world",
image="nginx:latest",
port=80,
env_vars={"BACKGROUND_COLOR": "blue"}
)
# Get deployment URL
print(f"Deployment URL: {deployment.url}")
import { ContainerEngineClient } from 'container-engine-sdk';
// Initialize client
const client = new ContainerEngineClient({ apiKey: 'your-api-key' });
// Deploy a container
async function deployContainer() {
const deployment = await client.deploy({
appName: 'hello-world',
image: 'nginx:latest',
port: 80,
envVars: { BACKGROUND_COLOR: 'blue' }
});
console.log(`Deployment URL: ${deployment.url}`);
}
deployContainer();
Container Engine provides a full suite of API endpoints to manage the complete lifecycle of your deployments:
POST /v1/deployments # Create a new deployment
GET /v1/deployments # List all deployments
GET /v1/deployments/{id} # Get deployment details
PUT /v1/deployments/{id} # Update a deployment
DELETE /v1/deployments/{id} # Delete a deployment
GET /v1/deployments/{id}/logs # Stream deployment logs
Map your own domain name to your deployment:
curl -X POST https://api.[your-domain]/v1/deployments/{id}/domains \
-H "Authorization: Bearer <your-api-key>" \
-H "Content-Type: application/json" \
-d '{
"domain": "myapp.example.com"
}'
Scale your application horizontally to handle more traffic:
curl -X PATCH https://api.[your-domain]/v1/deployments/{id}/scale \
-H "Authorization: Bearer <your-api-key>" \
-H "Content-Type: application/json" \
-d '{
"replicas": 5
}'
Configure custom health checks for your application:
curl -X POST https://api.[your-domain]/v1/deployments \
-H "Authorization: Bearer <your-api-key>" \
-H "Content-Type: application/json" \
-d '{
"appName": "hello-world",
"image": "nginx:latest",
"port": 80,
"healthCheck": {
"path": "/health",
"initialDelaySeconds": 5,
"periodSeconds": 10
}
}'
Container Engine takes security seriously at every layer:
+------------------------+ +------------------------+ +------------------------+
| Authentication Layer | | Network Security | | Runtime Security |
+------------------------+ +------------------------+ +------------------------+
| - API Key Auth | | - Auto TLS/SSL | | - Container Isolation |
| - OAuth 2.0 Support | | - Network Policies | | - Resource Limits |
| - Rate Limiting | | - DDoS Protection | | - Vulnerability Scans |
+------------------------+ +------------------------+ +------------------------+
We enthusiastically welcome contributions to the Container Engine project! Whether you're fixing bugs, adding features, improving documentation, or helping with tests, your input is valuable.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request
Container Engine includes an automated setup script that handles dependency installation and environment configuration:
# Clone the repository
git clone https://github.com/ngocbd/Open-Container-Engine.git
cd Open-Container-Engine
# Make setup script executable
chmod +x setup.sh
# Check system dependencies
./setup.sh check
# Full automated setup (installs dependencies if missing)
./setup.sh setup
# Start development server
./setup.sh dev
# Get help and see all available commands
./setup.sh help
# Development commands
./setup.sh build # Build the project
./setup.sh test # Run Rust tests
./setup.sh format # Format code
./setup.sh lint # Run linting
# Integration testing
make test-setup # Setup integration test environment
make test-integration # Run comprehensive API integration tests
make test-integration-verbose # Run integration tests with verbose output
make test-clean # Clean integration test environment
# Database management
./setup.sh db-up # Start database services
./setup.sh db-down # Stop database services
./setup.sh db-reset # Reset database and volumes
./setup.sh migrate # Run database migrations
./setup.sh sqlx-prepare # Prepare SQLx for offline compilation
# Docker operations
./setup.sh docker-build # Build Docker image
./setup.sh docker-up # Start all services with Docker
./setup.sh docker-down # Stop all Docker services
# Cleanup
./setup.sh clean # Clean build artifacts
If you prefer manual setup or the automated script doesn't work for your system:
# Install Rust and Cargo
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh
# Install SQLx CLI
cargo install sqlx-cli --no-default-features --features native-tls,postgres
# Start database services
docker compose up postgres redis -d
# Create environment file
cp .env.example .env
# Run migrations
export DATABASE_URL="postgresql://postgres:password@localhost:5432/container_engine"
sqlx migrate run
# Prepare SQLx for offline compilation
cargo sqlx prepare
# Build and run
cargo build
cargo run
Once the server is running, you can access:
- Health Check: http://localhost:3000/health
- OpenAPI Specification: http://localhost:3000/api-docs/openapi.json
- API Endpoints: All endpoints are documented in the OpenAPI spec
The setup script automatically checks for and installs:
- Rust (latest stable version)
- Docker & Docker Compose
- Git & curl
- Python 3 (optional, for development tools)
- SQLx CLI (for database migrations)
Container Engine includes a comprehensive test suite to ensure API reliability and functionality.
We maintain a complete integration test suite using pytest that validates all API endpoints:
- 93 integration tests covering every API endpoint
- Automated test environment with Docker management
- Authentication testing for JWT tokens and API keys
- Error case validation for proper error handling
- Response format verification ensuring API consistency
# Setup test environment (install Python dependencies)
make test-setup
# Run all integration tests
make test-integration
# Run tests with verbose output
make test-integration-verbose
# Run specific test category
pytest -m auth # Authentication tests
pytest -m deployment # Deployment tests
pytest -m monitoring # Monitoring tests
# Clean up test environment
make test-clean
- Authentication (13 tests): Registration, login, logout, token refresh
- API Keys (12 tests): Creation, listing, revocation, authentication
- User Profile (15 tests): Profile management, password changes
- Deployments (23 tests): CRUD operations, scaling, lifecycle management
- Monitoring (11 tests): Logs, metrics, status endpoints
- Domains (12 tests): Custom domain management
- Health Check (3 tests): Server health monitoring
- Infrastructure (4 tests): Test framework validation
Integration tests run automatically on every commit to the main branch via GitHub Actions, ensuring:
- Code quality through linting and formatting checks
- Database compatibility with PostgreSQL
- Redis connectivity and caching functionality
- Complete API endpoint validation
For detailed testing documentation, see tests/README.md and INTEGRATION_TESTS.md.
Rust unit tests are available for core functionality:
# Run Rust unit tests
cargo test
# Run with verbose output
cargo test -- --nocapture
We're continuously improving Container Engine with new features and enhancements:
- Q4 2025: Multi-cluster deployment support and advanced traffic routing
- Q1 2026: Native serverless function support
- Q2 2026: Advanced monitoring and observability features
- Q3 2026: Machine learning model deployment specialization
Distributed under the MIT License. See LICENSE.txt
for more information.
MIT License
Copyright (c) 2025 Container Engine Contributors
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files...
- Website: [your-domain]
- Documentation: [docs.your-domain]
- GitHub: github.com/ngocbd/Open-Container-Engine
- Community: Join our Slack
- Twitter: @ContainerEngine
Special thanks to all contributors and the open-source projects that make Container Engine possible, including Kubernetes, Docker, and the vibrant cloud-native ecosystem.