RETIRED, Fuel UI
Go to file
Mike Scherbakov 4cf3fd3cfa rm requirements.txt; new line in help of Makefile; README.md update. 2012-07-06 17:05:12 +04:00
bin Cookbook Attributes support in Nailgun. 2012-07-04 15:43:49 +04:00
binaries@d0ec020096 Added ipaddr egg dependency 2012-07-01 16:16:02 +04:00
bootstrap building bootstrap images via make calling bootstrapbuild.sh script 2012-06-22 21:01:17 +04:00
cookbooks Removed mysql cook from cookbooks, replaced by the one in cooks/ 2012-07-06 17:05:12 +04:00
cooks@9c5a34ed28 [cooks] Added rabbitmq cookbook 2012-07-06 12:50:38 +04:00
devops Refactored integration tests, integrated them with Make 2012-06-20 19:53:30 +04:00
gnupg Added Make rule to build Nailgun installation iso 2012-06-13 11:44:40 +04:00
iso added epel repository to centos repo list 2012-07-05 14:18:35 +04:00
nailgun Getting rid of two fields for tasks, preparations for task handling on UI side 2012-07-06 16:58:20 +04:00
provision worked on provision, not finished yet 2012-07-04 17:07:57 +04:00
scripts exposed password not empty 2012-07-06 15:43:02 +04:00
test bugfix in task checking for integration test 2012-07-04 17:15:52 +04:00
vagrant/cookbooks Added ipaddr egg dependency 2012-07-01 16:16:02 +04:00
.gitignore Added build directory to .gitignore 2012-06-15 22:00:03 +04:00
.gitmodules Changed url for cooks 2012-06-29 19:19:08 +04:00
Makefile rm requirements.txt; new line in help of Makefile; README.md update. 2012-07-06 17:05:12 +04:00
README.md rm requirements.txt; new line in help of Makefile; README.md update. 2012-07-06 17:05:12 +04:00
Vagrantfile Added one more cookbook location to Vagrantfile 2012-07-06 01:28:15 +04:00
config.mk building bootstrap images via make calling bootstrapbuild.sh script 2012-06-22 21:01:17 +04:00
requirements-deb.txt added some packages in requirement-debs.txt 2012-06-26 17:15:11 +04:00
requirements-rpm.txt Added RPM deps for Mysql cookbook 2012-07-06 17:05:12 +04:00
rules.mk Fixed rule for .dir files 2012-06-20 19:03:39 +04:00

README.md

NAILGUN

How to run Nailgun app from fixtures

Install application dependencies (eggs): cd scripts/ci/ sudo chef-solo -c solo.rb -j solo.json cd -

Remove old DB:

cd nailgun rm -f nailgun.sqlite

Sync DB:

./manage.py syncdb --noinput

Load data from fixtures:

./manage.py loaddata sample_environment

Run application:

./manage.py runserver

Access Web UI at http://localhost:8000/

Deploying virtual environment

Using vagrant:

Note: uncomment config.vm.forward_port 8000, 8000 in Vagrantfile for working with django webui.

For VM deployment run: vagrant up ubuntu_testbed

The working directory is /vagrant.

W/O vagrant:

Installing chef (source):

~$ echo "deb http://apt.opscode.com/ `lsb_release -cs`-0.10 main" | sudo tee /etc/apt/sources.list.d/opscode.list

~$ sudo mkdir -p /etc/apt/trusted.gpg.d

~$ gpg --keyserver keys.gnupg.net --recv-keys 83EF826A

~$ gpg --export packages@opscode.com | sudo tee /etc/apt/trusted.gpg.d/opscode-keyring.gpg > /dev/null

~$ sudo apt-get update && sudo apt-get install opscode-keyring

~$ sudo apt-get install chef

Installing dependencies

~$ cd scripts/ci && chef-solo -l debug -c solo.rb -j solo.json

Testing

Nailgun:

Unit tests: make test-unit or nailgun/run_tests.sh Integration tests: make test-integration

Layout

Makefile - the global product makefile
Vagrantfile - for the vagrant dev vms
bin/
    create_release - upload a release json file to nailgun (see e.g. scripts/ci/sample-release.json)
    deploy - invoked on a node to deploy; downloads and executes recipes
    install_cookbook - uploads cookbooks to nailgun admin API
binaries/ - submodule for binaries such as packages and ISO-files
bootstrap/ - creating a bootstrap image (aka crowbar sledgehammer) for nodes (initrd, configuration files, packages etc) It needed to be refactored to use clear make without calling additional shell scripts.
cookbooks/ - chef cookbooks to install Nailgun application
    agent/ - node agent. Sends ohai data to admin node.
    nailgun/ - nailgun server (not slave node!)
    others obvious
cooks/ - submodule with Cookbooks to be loaded in Nailgun app. OpenStack cookbooks will be here.
devops/ - Mirantis CI framework, used by integration tests (./test/integration/). Installed on the master, not slave.
gnupg/
iso/ - creating a main iso to install admin node
nailgun/ - server
    manage.py, run_tests.sh - django standard
    monitor.py - restart server when django conf files change
    nailgun/ - django app 
        apps: nailgun.api at api/, nailgun.webui (fully static) at /
        models: recipe, role, release, node, cluster
        tasks.py - django-celery tasks submitted from api/handlers.py: deploy cluster [sub: deploy node]
            MOST IMPORTANT TASK: deploy_cluster
                Create databags for nodes
                Provision node with Cobbler
                ssh node and call /opt/nailgun/bin/deploy
        api/ - nailgun.api django app; JSON API
            main entities in REST API: task, recipe/release/role, node, cluster
            
scripts/
    agent/ - development scripts to test agent cookbook
    ci/ - scripts for CI, sample-cook - cookbook for testing
test/ - integration tests [TODO figure out more]
vagrant/ - cookbooks for use by the vagrant vm
requirements-deb.txt - debian packages needed for Ubuntu slave node repository
requirements-rpm.txt - debian packages needed for CentOS slave node repository
rules.mk - it is just some make macroses