Fatih Degirmenci | f4a2bbf | 2020-01-14 15:59:15 +0000 | [diff] [blame] | 1 | .. _framework-user-guide: |
Fatih Degirmenci | 66d1e60 | 2020-01-13 12:50:03 +0000 | [diff] [blame] | 2 | |
Fatih Degirmenci | f4a2bbf | 2020-01-14 15:59:15 +0000 | [diff] [blame] | 3 | =========================================== |
| 4 | Cloud Infra Automation Framework User Guide |
| 5 | =========================================== |
Fatih Degirmenci | 66d1e60 | 2020-01-13 12:50:03 +0000 | [diff] [blame] | 6 | |
| 7 | Introduction |
| 8 | ============ |
| 9 | |
Fatih Degirmenci | f4a2bbf | 2020-01-14 15:59:15 +0000 | [diff] [blame] | 10 | Cloud Infra Automation Framework provides one-command deployments |
| 11 | of various open source cloud technologies and different configurations |
| 12 | of those. |
| 13 | |
| 14 | This guide is structured in a way to give the users the most basic |
| 15 | way to start using the framework. Later sections are structured after |
| 16 | the technologies as they have differences such as the target environment |
| 17 | support and so on. |
| 18 | |
| 19 | Running Your First Deployment |
| 20 | ============================= |
| 21 | |
| 22 | In order to give a quick try to framework and see its capabilities, |
| 23 | you need to run **3** commands in total. Once the execution of the command |
| 24 | is completed, you will have fully functional platform which you can play |
| 25 | with or get rid of it and deploy another and perhaps different one |
| 26 | that serves your needs better. |
| 27 | |
| 28 | Requirements |
| 29 | ------------ |
| 30 | |
| 31 | Before proceeding with the steps, it is important to list the requirements |
| 32 | for this simple stack. You need to have a decent Linux computer with |
| 33 | the distro and specs below. |
| 34 | |
| 35 | * Linux Distribution: Ubuntu 1804 |
| 36 | * Minimum no of cores: 10 |
| 37 | * Minimum RAM: 14G |
| 38 | * Minimum Disk Space: 150G |
| 39 | |
| 40 | If you do not have a computer which meets the minimum requirements, you can |
| 41 | always reach out to Nordix Infra Team on `Nordix Discuss Maillist <https://lists.nordix.org/mailman/listinfo/discuss>`_ |
| 42 | and asks to borrow resources for trying things out. |
| 43 | |
| 44 | Deploy Now! |
| 45 | ----------- |
| 46 | |
| 47 | As promised above, here are the commands you need to run to get your |
| 48 | first deployment started. We will start with cloning the Git repository |
| 49 | where the framework is developed and version controlled followed by the |
| 50 | actual command to initiate the deployment. |
| 51 | |
| 52 | 1. Clone the repository from Nordix Gerrit |
| 53 | |
| 54 | | ``git clone https://gerrit.nordix.org/infra/engine.git`` |
| 55 | |
| 56 | 2. Navigate to engine directory in your clone |
| 57 | |
| 58 | | ``cd engine/engine`` |
| 59 | |
| 60 | 3. Issue the command to initiate the deployment |
| 61 | |
| 62 | | ``./deploy.sh`` |
| 63 | |
| 64 | and that's it. It will take approximately 40 to 50 minutes for deployment |
| 65 | to complete. |
| 66 | |
| 67 | What Just Happened and What You Have There? |
| 68 | ------------------------------------------- |
| 69 | |
| 70 | When you issue *deploy.sh* command, the framework starts with preparing |
| 71 | your machine by installing few requirements which you can see by looking |
| 72 | into *engine/bindep.txt* followed by creating of Python virtualenv to |
| 73 | install Python dependencies listed in *engine/requirements.txt*. |
| 74 | |
| 75 | Once the basic preparation is done, the next step is cloning the repositories |
| 76 | that are needed for framework to continue with the rest. |
| 77 | |
| 78 | After completion of this step, framework creates 2 libvirt VMs and installs the |
| 79 | provisioning tool `OpenStack Bifrost <https://docs.openstack.org/bifrost/latest/>`_. |
| 80 | After the installation of the provisioning tool, the VMs are booted up |
| 81 | and the provisioning process starts. The VMs will be PXE booted and they |
| 82 | are supplied the operating system images which is Ubuntu 1804. They |
| 83 | are remotely controlled by Bifrost to power cycle which the framework |
| 84 | uses `OpenStack VirtualBMC <https://docs.openstack.org/virtualbmc/latest/user/index.html>`_. |
| 85 | |
| 86 | After the completion of the provisioning, the VMs have remote connectivity |
| 87 | but their configuration is incomplete. At this step, the framework proceeds |
| 88 | with various configuration steps on the VMs such as installing operating system |
| 89 | packages network configuration and so on. |
| 90 | |
| 91 | Basic configuration of the VMs is followed by yet another clone operation |
| 92 | which we pull down the installer for the platform we have chosen to install. |
| 93 | The default configuration that gets deployed by the framework is Kubernetes |
| 94 | with Calico Network Plugin. The framework uses another open source tool |
| 95 | from CNCF named `Kubespray <https://github.com/kubernetes-sigs/kubespray>`_. |
| 96 | Kubespray is a `CNCF certified Kubernetes Distribution <https://www.cncf.io/certification/software-conformance/>`_ |
| 97 | so what you get in the end is pretty solid. In addition to Kubernetes itself |
| 98 | with Calico Network Plugin, the stack will have `Helm <https://helm.sh/>`_ |
| 99 | and `Prometheus <https://prometheus.io/>`_ so you can use this deployment |
| 100 | for real development purposes. |
| 101 | |
| 102 | Once the installation of Kubernetes together with the components end, you |
| 103 | will be presented with a summary and the script will exit successfully - at |
| 104 | least this is what we hope at this point. You should have **kubectl** and |
| 105 | **helm** client installed on your machine to operate against Kubernetes cluster. |
| 106 | |
| 107 | We already noted what you get in the end but we list them here as well to |
| 108 | summarize the deployment you have. |
| 109 | |
| 110 | * Platform: Kubernetes |
| 111 | * Network Plugin: Calico |
| 112 | * Storage: CEPH installed using Rook |
| 113 | * Application Development: Helm |
| 114 | * Metrics/Monitoring: Prometheus |
| 115 | |
| 116 | Congratulations, you made it! \o/ |
| 117 | |
| 118 | Scenarios Supported by Cloud Infra Automation Framework |
| 119 | ======================================================= |
| 120 | |
| 121 | As noted in earlier sections, the framework supports various scenarios. In |
| 122 | this section, we will provide steps to deploy those scenarios and operate |
| 123 | against them. This part of the guide is structured after the platforms |
| 124 | as the scenarios are platform specific. |
| 125 | |
| 126 | OpenStack Scenarios |
| 127 | ------------------- |
| 128 | |
| 129 | Engine currently supports single OpenStack scenario with OVS and CEPH. |
| 130 | Deployment of this scenario is same as the default scenario you deployed |
| 131 | by following the steps documented in *Running Your First Deployment* |
| 132 | with few additional parameters to set the right scenario. |
| 133 | |
| 134 | |
| 135 | The machine requirements are same as the one you deployed earlier but |
| 136 | putting them here as well for the sake of completion. |
| 137 | |
| 138 | |
| 139 | * Linux Distribution: Ubuntu 1804 |
| 140 | * Minimum no of cores: 10 |
| 141 | * Minimum RAM: 14G |
| 142 | * Minimum Disk Space: 150G |
| 143 | |
| 144 | |
| 145 | What happens during the deployment process is nearly the same as the default |
| 146 | scenario as well - the framework creates libvirt VMs, provisions them using |
| 147 | Bifrost, and configures them. The main difference here is the configuration |
| 148 | as the network setup for OpenStack deployments is different from Kubernetes |
| 149 | deployments. |
| 150 | |
| 151 | |
| 152 | Provisioning is followed by installation of OpenStack which is perhaps the |
| 153 | biggest difference comparing to the deployment of the Kubernetes based default |
| 154 | scenario. For OpenStack installation, framework utilizes OpenStack installer |
| 155 | `Kolla-Ansible <https://docs.openstack.org/kolla-ansible/latest/>`_. |
| 156 | |
| 157 | |
| 158 | Now the commands to issue. |
| 159 | |
| 160 | 1. Clone the repository from Nordix Gerrit - *you can skip this step if you have the clone already* |
| 161 | |
| 162 | | ``git clone https://gerrit.nordix.org/infra/engine.git`` |
| 163 | |
| 164 | 2. Navigate to engine directory in your clone |
| 165 | |
| 166 | | ``cd engine/engine`` |
| 167 | |
| 168 | 3. Issue the command to initiate the deployment |
| 169 | |
| 170 | | ``./deploy.sh -d kolla -s os-nosdn-nofeature -c`` |
| 171 | |
| 172 | Once the installation of OpenStack together with the components end, you |
| 173 | will be presented with a summary and the script will exit successfully. |
| 174 | Your machine will have the OpenStack clients installed and openrc file |
| 175 | so you can operate against your deployment. Please note that you may |
| 176 | need to activate Python virtual environment to access them which you |
| 177 | can do using the command below. |
| 178 | |
| 179 | | ``source /opt/engine/.venv/bin/activate`` |
| 180 | |
| 181 | We already noted what you get in the end but we list them here as well to |
| 182 | summarize the deployment you have. |
| 183 | |
| 184 | |
| 185 | * Platform: OpenStack |
| 186 | * Networking: Neutron with OVS |
| 187 | * Storage: CEPH |
| 188 | |
| 189 | |
| 190 | Installed OpenStack components are |
| 191 | |
| 192 | * Keystone |
| 193 | * Nova |
| 194 | * Neutron |
| 195 | |
| 196 | - OVS |
| 197 | - VXLAN |
| 198 | |
| 199 | * Heat |
| 200 | * Glance |
| 201 | * Cinder |
| 202 | |
| 203 | - CEPH as volume backend |
| 204 | - NFS as backup backend |
| 205 | |
| 206 | * Horizon |
| 207 | |
| 208 | Installed infra services are |
| 209 | |
| 210 | * RabbitMQ |
| 211 | * MariaDB |
| 212 | * Memcached |
| 213 | * Chrony |
| 214 | * Fluentd |
| 215 | |
| 216 | Kubernetes Scenarios |
| 217 | -------------------- |
| 218 | |
| 219 | TBD |
| 220 | |
| 221 | ONAP Scenarios |
| 222 | -------------- |
| 223 | |
| 224 | TBD |
| 225 | |
| 226 | Testing Your Deployments |
| 227 | ======================== |
| 228 | |
Fatih Degirmenci | 66d1e60 | 2020-01-13 12:50:03 +0000 | [diff] [blame] | 229 | TBD |