✨ .
⭐ .
⭐ ⭐ .
. ⭐ ⭐ ⭐ .
⭐ ORION .
⭐ ⭐ .
⭐ ⭐ .
. ✨ .
. .
Welcome to CinC 🚀
This project provides an automated script to set up a distributed serverless simulator using LXD containers and MicroK8s. Each node in the cluster runs inside an LXD container and serves as a functional part of the serverless simulation environment. The setup is fully automated, including networking, container initialization, and Kubernetes deployment.
- Automated LXD Cluster Creation: Sets up a new LXD cluster with dynamic networking and storage.
- MicroK8s Integration: Deploys a lightweight Kubernetes environment in an isolated container.
- Dynamic Network Configuration: Uses LXD's fan networking to enable cross-node communication.
- Automatic Node Detection: The system dynamically detects the node's IP, subnet, and hostname.
- Secure and Scalable: Supports additional nodes joining the cluster seamlessly.
Before running this script, ensure that:
- The host machine runs Ubuntu 20.04+.
- LXD and Snap are installed.
- Sudo privileges are available.
- Clone the repository or copy the script:
git clone <repository-url> cd <repository-folder>
- Make the script executable:
chmod +x setup_simulator.sh
- Run the script as root (or use sudo):
sudo ./setup_simulator.sh
- Detects primary network interface and assigns a subnet.
- Configures IP forwarding and iptables rules.
- Initializes an LXD cluster using a dynamically generated configuration.
- Creates a specialized LXD profile for MicroK8s.
- Downloads and applies the correct MicroK8s profile (ZFS or EXT4 support).
- Launches a new LXD container running MicroK8s.
- Configures AppArmor profiles to ensure smooth operation.
After running the script, your distributed serverless simulator will be up and running. You can interact with the environment as follows:
lxc cluster list
lxc list
lxc exec master -- bash
lxc exec master -- microk8s status --wait-ready
To add more nodes, use:
lxc cluster add <node-name>
Then, join the new node with the generated token.
To remove the cluster and containers:
lxc delete master --force
lxc profile delete microk8s
lxd recover
- Multi-node scaling with automatic joining.
- Integration with Knative for full serverless workflows.
- Metrics and Logging via Prometheus and Grafana.
This project is open-source and follows the MIT License.
🚀 Now you're ready to build and experiment with a distributed serverless environment!