Currently Ganeti Web Manager lacks proper packaging. If a sysadmin decides to install GWM, he/she should be able to simply install via package manager and be done.
This project intends to build tools (or leverage existing ones) to automate creation of .deb and .rpm Ganeti Web Manager packages for Linux distributions. The actual work will also include further modularization of GWM, workflow automation and packages for opt-in GWM features, like VMs metric system (GSoC 2012).
Installation of GWM currently requires these steps:
I intend to shorten this path for the end-user to just these steps:
Actual work includes:
Additional steps will be taken into account if I work ahead of schedule.
GWM modularization: separate Django applications for Nodes, Clusters, Virtual Machines, and maybe more. This involves separating appropriate views, models and templates into Django apps and actually might require changing GWM project structure into what is generated by Django since version 1.4.
GWM dependencies: documentation hosted on Read The Docs, unittests, packages uploaded to PyPI.
Building .deb packages: with help from git-buildpackage.
Building .rpm packages: not with Python's very own distutils, but rather with Fedora's mock.
At first I suggest to automate building distribution packages via GIT repository hooks, for example: a developer creates a new tag in repository, then a building script is invoked. Of course this can be done manually, too.
Structuring GWM projects: like they did at Synnefo. Everything mostly comes down to including configuration from /etc/ -- here are adequate lines.
What instead of Fabric for development process? The usual way Python projects are being developed is: set up virtual environment, install dependencies via pip (even from requirements_development.txt file). Getting rid of Fabric actually lengthens the list of steps to start developing GWM, but the advantages are:
Python virtual environments are known for not being portable (even though they claim to be). But we should not rely on end-user OS to provide all our dependencies. Thus DEB/RPM packages containing almost whole GWM project (with external dependencies) is what we should be trying to reach.
Hynek Schlawack wrote great article (Python Application Deployment with Native Packages) on how to achieve this goal.
Some keypoints and conclusions from his article:
Lightweight web server that might end up being included with GWM package: Cherokee.
RPM packages have higher priority than DEBs. When building RPMs, I have to take into account different distributions. mock helps with that issue.
I do not plan to go on any longer than one day vacation. Only time I won't spend writing software during GSoC is when I have end term exams.