- Jinja 68.6%
- Python 15.7%
- Shell 15.2%
- Dockerfile 0.5%
| bin | ||
| ngine_io | ||
| privazio/vdc | ||
| .gitignore | ||
| .gitlab-ci.yml | ||
| .gitmodules | ||
| .vdc.rev | ||
| Dockerfile | ||
| Readme.md | ||
Privazio Virtual Datacenter
VDC stands for virtual datacenter.
VDC is an opinionated way to run an Apache Cloudstack (ACS) private cloud.
How is VDC opinionated? what does privazio stand for?
Privazio's goal
Anybody should be able to manage cloud infrastructure directly from metal. Privazio aims to lower the barrier of entry to private clouds by lowering complexity and costs.
Privazio is mainly targeted at:
- enthusiasts
- small companies and/or startups
- workgroups / development teams
Privazio does not target specifically hyper-scale and ultimate optimization of hardware resources.
Privazio's trade-offs
One can not have it all, sometimes trade offs are required. When making trade-offs VDC will favor:
- High Automation versus ample feature set
- Low cost hardware versus high end hardware/features
- Privacy versus optimal performance
- Flexibility versus optimal performance
- Flexibility to manage multiple environments versus hyperscale
What VDC Provides
VDC is a tool to fully automate the deployment of ACS according to the trade-offs above.
VDC is delivered as a dockerized ansible distribution+collections+python dependencies tested against a particular version of ACS and underlying OS.
An VDC.sh script is also provided to facilitate the transparent usage of the VDC docker image against multiple environments
Architecture
Software Defined Core Network
VCD will setup your servers and deliver ACS over a Software Defined Network.
The SDNetwork is currently implemented by TincVPN.
As a result it is possible to use widely available unmanaged 1G switch across the whole installation, hosts require only one network card.
It is also possible to distribute the ACS deployment between your small office/home office or lab and your datacenter.
A typical deployment may include a dozen of hosts placed at your SOHO and a couple of hosts placed at your datacenter.
TincVPN allows to distribute L2 traffic between hosts in an encrypted manner.
The Software Defined Network is pretty independent from ACS and other implementations are possible.
In the era of fiber the network performance is adequate for most workloads, however distributed secondary storage is discouraged in favor of local storage. High availability is expected to be provided at higher levels (clustering, etc).
Main Modules
VDC is a set of playbooks split in two groups
- VRack: Stands for virutal Rack and it is responsible for configuring the metal: OS, Storage, Firewall, and SD Network (sometimes referred as mesh)
- cloudstack-*: Cloudstack playbooks that will install the compute nodes, manager, mysql and secondary nfs storage.
- ca: A minimal Certificate generation tool is provided to generate certificates from an intermediate CA. This is meant to be used in conjuction with a certificate authority management software such as XCA or similar.
Hardware / Software requirments
The minim hardware you will require is:
- A raspberry pi4 (4GB) to implement the management server
- A x86 server as compute host with minim 4GB ram
- A 1G switch
Software requirements:
Currently Ubuntu 18.04 is the reference OS (both for Compute and Management servers) both for x86 and arm. Centos 7 is also been tested but lags behind Ubuntu.
Recommended Additional HW Software
When delivery public traffic from the software defined network to the public network:
- A switch with rudimentary handling of VLANs can help
- A server with more than 1 interface can help
OPNSense is recommended as head router of the deployment.
For autmated installation of the base OS, MAAS on a raspberry pi is recommended.
Sourcing Affordable Hardware
When setting up a small cluster or lab, I found the following resources useful:
- Raspberry pi 4GB (as manager node or maas)
- PCEngines APU (as manager/router)
- Hardkernel ODroid-H2 (as fanless 32GB capable compute node for SOHO/Lab)
Base OS configuration:
When installing your servers use:
- LVM storage
- root LV of 10GB
- swap LV sized wisely according to your RAM
- Leave free space int he VG.
- Using LUKS full disk encryption is recommended and playbooks for remote SSH/unlock are provided.
Getting Started
VDC includes CD/CI testing, check the gitlab project and the test/ci directory where a sample environment is built and tested.
Feel free to ask for help as required.
Links and Resources
- Apache Cloudstack
- Ansible
- Ansible Collection for Apache CloudStack Clouds
- XCA
- [OPNSense] (https://opnsense.org/)
- [TincVPN] (https://tinc-vpn.org/)
- [Ferm] (http://ferm.foo-projects.org/)
- [MAAS] (https://maas.io/)
Author
Rafael del Valle (rvalle@privaz.io)