Automated setup of M-CORD EPC

Change-Id: Ic6935b6a29bc322aa46120aaf421a23dc321cf3d
(cherry picked from commit 2ee4aa80c4b06df4aed730af3e3cb7da64bed5dc)
5 files changed
tree: 60186a3392b91f411a41bf0d619187fec06cb4bb
  1. .gitignore
  2. LICENSE.txt
  3. README.md
  4. add-bootstrap-containers-playbook.yml
  5. add-onboard-containers-playbook.yml
  6. ansible.cfg
  7. api-test-playbook.yml
  8. bootstrap-dev-env.yml
  9. build-core-image-playbook.yml
  10. build-platform-install-playbook.yml
  11. collect-diag-playbook.yml
  12. compute-node-refresh-playbook.yml
  13. copy-cord-playbook.yml
  14. copy-profile-playbook.yml
  15. cord-automation-playbook.yml
  16. cord-compute-maas-playbook.yml
  17. cord-config-playbook.yml
  18. cord-fabric-pingtest.yml
  19. cord-refresh-fabric.yml
  20. credentials/
  21. deploy-computenode-playbook.yml
  22. deploy-elasticstack-playbook.yml
  23. deploy-mavenrepo-playbook.yml
  24. deploy-onos-playbook.yml
  25. deploy-openstack-playbook.yml
  26. devel-tools-playbook.yml
  27. docs/
  28. ecord-test-subscriber-playbook.yml
  29. filter_plugins/
  30. glance-images-playbook.yml
  31. instantiate-monitoringservice-playbook.yml
  32. inventory/
  33. library/
  34. mcord-ng40-test-playbook.yml
  35. mcord-spirent-test-playbook.yml
  36. mcord-test-playbook.yml
  37. mock-ecord-container-test.yml
  38. mock-rcord-container-test.yml
  39. monitoringagent-infra-install-config.yml
  40. monitoringagent-infra-install.yml
  41. monitoringservice-enable-exampleservicemonitoring.yml
  42. monitoringservice-enable-inframonitoring-config.yml
  43. monitoringservice-enable-inframonitoring.yml
  44. monitoringservice-enable-vsgmonitoring.yml
  45. monitoringservice-test-exampleservicemetrics.yaml
  46. monitoringservice-test-inframetrics.yaml
  47. monitoringservice-test-initial.yaml
  48. monitoringservice-test-vsgmetrics.yaml
  49. onboard-exampleservice-playbook.yml
  50. onboard-monitoringservice-playbook.yml
  51. onboard-openstack-playbook.yml
  52. onboard-profile-playbook.yml
  53. onos-debug-playbook.yml
  54. pod-test-playbook.yml
  55. prep-buildnode-playbook.yml
  56. prep-computenode-playbook.yml
  57. prep-headnode-playbook.yml
  58. prereqs-check-playbook.yml
  59. profile_manifests/
  60. publish-images-playbook.yml
  61. publish-platform-install-playbook.yml
  62. roles/
  63. scripts/
  64. ssh_pki/
  65. start-xos-playbook.yml
  66. teardown-onos-playbook.yml
  67. teardown-openstack-playbook.yml
  68. teardown-xos-playbook.yml
  69. vtn-refresh-playbook.yml
  70. xos-container-test.yml
README.md

CORD platform-install

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.

Credentials

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.

Creating a new CORD profile

To create a new CORD profile, you should create a .yaml variables file in profile_manifests/ with the name of your profile (ex: my-profile.yaml), and populate it with your configuration.

Making changes and lint checking your changes

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.

Specific profiles notes

opencloud

Used as a part of the OpenCloud deployment. Similar to rcord.

rcord

This is a part of the R-CORD deployment - start using the steps specified in that repo.

This profile is designed to integrate XOS with physical infrastructure pieces like MaaS, OpenStack, and ONOS. See the CORD-in-a-Box Quick Start Guide for how to set up a virtual multi-node R-CORD pod on a single host.

ecord

E-CORD description goes here.

mcord

M-CORD description goes here.

Design Notes for Developers

Variables used in platform-install

cord_profile: name of the profile_manifest to use.

Paths on configuration node (where playbooks are run, may also be build node)

  • config_cord_dir location on configuration node of cord dir
  • config_cord_profile_dir location on configuration node of cord_profile dir
  • pki_dir, ssh_pki_dir: where SSL and SSH certificates are created on config node
  • credentials_dir - location where autogenerated passwords file are created

Paths on head node (target system operated on by playbooks)

  • head_cord_dir - where the cord directory is copied to on the head node (deprecated when we reach container-only deploys)
  • head_cord_profile_dir - location of the cord_profile directory on the head node
  • head_onos_cord_dir - location of the onos-cord directory on the head node
  • head_onos_fabric_dir - location of the onos-fabric directory on the head node

Style notes

Prefix every role file with the yaml start block and comment with name of file relative to role base.

---
# rolename/tasks/main.yml

When using templates, put the template filename and path within the role as a comment in the template so that it's easy to determine which template was used to create a file after it's been created.

If you use a variable that isn't created by the ansible setup task, define it in the role defaults file. The default value for anay variable must be the same across all role defaults.

Use the YAML style syntax for tasks, not the older = syntax, as the former is more likely to indent and syntax highlight properly in most editors.

Roles should always have the same outcome, so avoid using conditionals or tags to change the behavior of a role. These features should only be used for avoiding time-consuming tasks in an idempotent manner.