commit | a2763116253601c54c04d3838139a659d2d9a24b | [log] [tgz] |
---|---|---|
author | Zack Williams <zdw@cs.arizona.edu> | Tue Jan 03 11:38:38 2017 -0700 |
committer | Zack Williams <zdw@cs.arizona.edu> | Thu Feb 09 09:02:58 2017 -0700 |
tree | 5bd63c6c90f28309c96ad014847c7ad37802e148 | |
parent | 7bf357098777c6f64f28c14bf4a103c89fbfd1ae [diff] |
CORD-714 initial set of roles/playbooks bug fixes fix docker-compose logging, pull xos-base image dynamically add docker instances to ansible inventory after onboarding Bootstrap the onboarding synchronizer more defaults, reload vars after adding docker inventory move TOSCA templates to cord-profilea, random password on admin fixes for docker compose, paths in xos.yaml in jinja don't try to mangle XOS _config files (yet) create xos-test image make xos-test use locally build xosproject/xos add docker-compose v2 format networking fix docker-compose template path fixes, move ssh keys service names/paths aren't so simple added api-tests, teardown roles scan the onboarded docker-compose file for ansible inventory add various tests used by test-standalone profile fixes for API tests save test output to /tmp/<testname>.out, bugfixes autogenerate openstack keystone admin password, fix tests remove nonfunctional UI tests change location of cord_profile, use inventory to specify profile fix YAML escaping of backslashes in regex bugfixes after path change, add teardown playbook backout setting of cord_dir with ansible_user_dir which differs depending on context gradle build fixes, renaming fix yml/yaml naming issue null xos_images default added rcord/mcord frontend variants, exampleservice onboarding add missing role, help text in cord-bootstrap.sh bugfix create/run deployment.yaml by default allow teardown to handle partially built pods, bugfix to deployment.yaml generation add defaults, fix path for exampleservice revert yaml naming to ease testing, rename mocks debugging exampleservice onboarding, mounting volume in XOS container bugfix add volume mounts when creating xos_ui, don't double add to ansible inventory post-onboard TOSCA cnfig typo fixes, order of loading TOSCA config bits for cord-pod, some var renaming update documentation, rename to rcord doc fixes support for building just before XOS install, docs fix tests, refactor how compute nodes are configed, split vtn service config from adding a node remove build process from deploy repo inclusion/merge of PKI support typo bugfixes and change to use cord instead of opencord for install dir fix pki support fix ssh key paths update xos ui/bs ports, fix onboarding on vagrant have compute enlist script use same config file as other playbooks fix ports, add MaaS version of compute node enable script fix port and nodes.yaml loading generate API SSL cert for all profiles remove cord-app-build which is vestigial remove config dir default xos_ui_port in xos-ready role use xostosca from service-profie/cord-pod-ansible to handle POST form-encode fix nodes.yaml, variable name in xostosca, and include openstack properly copy cert chain to build into XOS container increase onboarding timeouts, don't restart docker fix ONOS app versions and network settings fix management_hosts network optional include fix management/fabric settings avoid modifying service#ONOS_CORD when adding nodes split out compute node and vtn config, put delay between fix template generation and fail on file not found rename vars to profile_manifests, fix redis include whitespace fix increase timeout reenable platform-check parameterize node_key path, set defaults and fix platform-check workaround for onboarding sync, minor fixes pause in middle of VTN bug workaround reload openstack config as well disable platform-check role as a test fixed head-diag role reapply VTN config during compute node enable Create exampleservice instance during test Change-Id: I87e171bcfa429e65e1075a1ee4c97de1e90a7dd5
This repository contains Ansible playbooks for installing and configuring software components that build a CORD POD: OpenStack, ONOS, and XOS.
It is used as a sub-module of the main CORD repository, but can independently bring up various CORD profiles for development work.
If you want to set up an entire CORD pod on physical hardware, or set up the Cord-in-a-Box deployment, you should start at the CORD repository.
There's a helper script, scripts/cord-bootstrap.sh. that will install development environment prerequisites on a Ubuntu 14.04 node. You can download it with:
curl -O ~/cord-bootstrap.sh https://github.com/opencord/platform-install/raw/master/scripts/cord-bootstrap.sh
Running the script will install the repo tool, Ansible, and Docker, as well as make a checkout of the CORD manifest into ~/cord
.
You can specify which gerrit changesets you would like repo to checkout using the -b
option on the script as documented here.
Once you have done this, if you're not already in the docker
group, you should logout and log back into your system to refresh your user account's group membership. If you don't do this, any docker command you run or ansible runs for you will fail. You can check your group membership by running groups
.
Once you log back in, you may want to run tmux
to maintain a server-side session you can reconnect to, in case of network trouble.
All of the commands below assume you're in the cord/build/platform-install
directory.
Credentials will be autogenerated and placed in the credentials/
directory when the playbooks are run, where the credential name is the filename, and the contents of the file is the password.
For most profiles the XOS admin user is named xosadmin@opencord.org
.
Most profiles are run by specifying an inventory file when running ansible-playbook
. Most of the time, you want to run the deploy-xos-playbook.yml
playbook.
For example, to run the frontend
config, you would run:
ansible-playbook -i inventory/frontend deploy-xos-playbook.yml
Assuming it runs without error, you can then explore the environment you've set up. When you're ready to tear down your environment, run:
ansible-playbook -i inventory/frontend teardown-playbook.yml
This will destroy all the docker containers created, and delete the ~/cord_profile
directory.
You can then re-run, or run a different profile.
To create a new CORD profile, you should:
inventory/
that defines the cord_profile
variable, with the name of your profile.[all:vars] cord_profile=my-profile
Create a .yaml variables file in profile_manifests/
with the name of your profile (ex: my-profile.yaml
), and populate it with your configuration.
To test the profile, run the deploy-xos-playbook.yml
playbook using your inventory profile: ansible-playbook -i inventory/my-profile deploy-xos-playbook.yml
Before commit, please run ./scripts/lintcheck.sh .
in the repo root, which will perform the same ansible-lint check that Jenkins performs when in review in gerrit.
This profile runs API tests for both the REST and TOSCA APIs. This can be done in an automated fashion:
ansible-playbook -i inventory/api-test api-test-playbook.yml
The XOS credentials in this config are padmin@vicci.org
and letmein
(until the tests are modified to support generated credentials).
Builds a basic XOS frontend installation, useful for UI testing and experimentation.
Builds a Mock R-CORD or Mock M-CORD pod, without running service synchronizers in a manner similar to frontend.
Used as a part of the OpenCloud deployment. Similar to rcord
.
Used as a part of the R-CORD deployment. Sets up infrastructure pieces including OpenStack (via Juju) and ONOS as well as XOS.