Remove undercloud deploy support
The openstack undercloud deploy command has been deprecated and will be removed. This change removes the support for this method via the undercloud-deploy role. Change-Id: I4c6a46d9dcee4efc38a3de682ecffacf529288b8
This commit is contained in:
parent
1f59d0c543
commit
9fd5582e18
|
@ -1,80 +0,0 @@
|
|||
---
|
||||
# EXPERIMENTAL FEATURE
|
||||
# set the working_dir on the undercloud
|
||||
working_dir: /home/stack
|
||||
|
||||
# Define a single controller node and a single compute node.
|
||||
overcloud_nodes:
|
||||
- name: control_0
|
||||
flavor: control
|
||||
virtualbmc_port: 6230
|
||||
|
||||
- name: compute_0
|
||||
flavor: compute
|
||||
virtualbmc_port: 6231
|
||||
|
||||
# Tell tripleo how we want things done.
|
||||
# Note: The order of the templates and arguments passed to heat matters.
|
||||
|
||||
extra_args: >-
|
||||
--ntp-server pool.ntp.org
|
||||
|
||||
network_isolation: true
|
||||
enable_pacemaker: false
|
||||
overcloud_ipv6: false
|
||||
|
||||
# containers config
|
||||
containerized_overcloud: false
|
||||
containerized_undercloud: true
|
||||
|
||||
# deploy the undercloud with containers
|
||||
undercloud_install_script: undercloud-deploy.sh.j2
|
||||
|
||||
# This enables TLS for the undercloud which will also make haproxy bind to the
|
||||
# configured public-vip and admin-vip.
|
||||
undercloud_generate_service_certificate: false
|
||||
|
||||
# This enables the deployment of the overcloud with SSL.
|
||||
ssl_overcloud: false
|
||||
|
||||
# If `run_tempest` is `true`, run tempests tests, otherwise do not
|
||||
# run them.
|
||||
tempest_config: false
|
||||
test_ping: true
|
||||
run_tempest: false
|
||||
tempest_workers: 4
|
||||
|
||||
# Config for custom tripleo-heat-templates
|
||||
# overcloud_templates_path: /home/stack/tripleo-heat-templates
|
||||
# overcloud_templates_repo: https://opendev.org/openstack/tripleo-heat-templates
|
||||
# # use templates_branch when not testing with an unmerged review
|
||||
# overcloud_templates_branch: master
|
||||
# # use templates_refspec when testing with an unmerged review
|
||||
# overcloud_templates_refspec:
|
||||
|
||||
# options below direct automatic doc generation by tripleo-collect-logs
|
||||
artcl_gen_docs: true
|
||||
artcl_create_docs_payload:
|
||||
included_deployment_scripts:
|
||||
- undercloud-deploy
|
||||
- overcloud-custom-tht-script
|
||||
- overcloud-prep-containers
|
||||
- overcloud-prep-flavors
|
||||
- overcloud-prep-images
|
||||
- overcloud-prep-network
|
||||
- overcloud-deploy
|
||||
- overcloud-deploy-post
|
||||
- overcloud-validate
|
||||
included_static_docs:
|
||||
- env-setup-virt
|
||||
table_of_contents:
|
||||
- env-setup-virt
|
||||
- undercloud-deploy
|
||||
- overcloud-custom-tht-script
|
||||
- overcloud-prep-containers
|
||||
- overcloud-prep-flavors
|
||||
- overcloud-prep-images
|
||||
- overcloud-prep-network
|
||||
- overcloud-deploy
|
||||
- overcloud-deploy-post
|
||||
- overcloud-validate
|
|
@ -0,0 +1,5 @@
|
|||
---
|
||||
other:
|
||||
- |
|
||||
The `openstack undercloud deploy` command has been removed. The support for
|
||||
this method of deployment in the `undercloud-deploy` role has been removed.
|
|
@ -145,47 +145,13 @@ TempURLs from OpenStack Object Storage (swift).
|
|||
Undercloud deployment methods
|
||||
-----------------------------
|
||||
|
||||
By default, the undercloud uses ``openstack undercloud install`` command,
|
||||
The undercloud uses ``openstack undercloud install`` command,
|
||||
`{{working_dir}}/undercloud.conf` config and the file coming from the
|
||||
``hieradata_override_file_classic_undercloud`` variable to set the hieradata
|
||||
overrides that will be used for the puppet deployment.
|
||||
overrides that will be used for the puppet deployment. Alternatively there is
|
||||
a heat yaml way to provide overrides as well. For these cases, hiera override
|
||||
data is consumed from ``hieradata_override_file_t_h_t_undercloud``.
|
||||
|
||||
However, there exists more methods for setting up the undercloud based on
|
||||
containers with the ``openstack undercloud install --use-heat`` and
|
||||
``openstack undercloud deploy`` commands. Both methods are based on
|
||||
tripleo-heat-templates. The former one provides the instack compatible
|
||||
`undercloud.conf` format. It may be requested via settings:
|
||||
```
|
||||
undercloud_install_cli_options: --use-heat
|
||||
undercloud_install_script: undercloud-install.sh.j2
|
||||
```
|
||||
And the latter deployment method is more "free to go". It can be
|
||||
enabled with:
|
||||
```
|
||||
containerized_undercloud: true
|
||||
undercloud_install_script: undercloud-deploy.sh.j2
|
||||
```
|
||||
For these cases, hiera override data is consumed from
|
||||
``hieradata_override_file_t_h_t_undercloud``.
|
||||
|
||||
Note, the containerized undercloud is a hacking mode for developers, that allows
|
||||
to test containerized components undercloud, with custom, like very minimal,
|
||||
setup layouts. Please do not expect more than that when using it.
|
||||
|
||||
To diverge TripleO Heat Templates installation scripts used to deploy/upgrade
|
||||
undercloud from the similar overcloud cases, use the following variables:
|
||||
|
||||
```yaml
|
||||
undercloud_composable_scenario: < similarly to composable_scenario for OC >
|
||||
undercloud_upgrade_composable_scenario: < similarly to upgrade_composable_scenario for OC >
|
||||
undercloud_prep_post_hook_script: < similarly to overcloud_prep_post_hook_script >
|
||||
download_undercloud_templates_rpm: < similarly to download_overcloud_templates_rpm >
|
||||
undercloud_tht_rpm_url: < similarly to tht_rpm_url for OC >
|
||||
undercloud_templates_path: < similarly to overcloud_templates_path >
|
||||
undercloud_templates_repo: < similarly to overcloud_templates_repo >
|
||||
undercloud_templates_branch: < similarly to overcloud_templates_branch >
|
||||
undercloud_templates_refspec: < similarly to overcloud_templates_refspec >
|
||||
```
|
||||
|
||||
Example Playbook
|
||||
----------------
|
||||
|
@ -200,140 +166,4 @@ Sample playbook to call the role
|
|||
roles:
|
||||
- undercloud-deploy
|
||||
```
|
||||
|
||||
Containerized dev environments (experimental feature)
|
||||
-----------------------------------------------------
|
||||
|
||||
Firstly, update or create a custom undercloud install script template. It can be
|
||||
found under the locally checked out tripleo-quickstart-extra repo (or at a remote
|
||||
host, if you prefer to apply ansible playbooks from a non local virthost). The
|
||||
template is located by the
|
||||
`roles/undercloud-deploy/templates/undercloud-deploy-my-dev.sh.j2` path.
|
||||
Once changes are done, update the ``undercloud_install_script`` var, like:
|
||||
|
||||
```yaml
|
||||
undercloud_install_script: undercloud-deploy-dev.sh.j2
|
||||
```
|
||||
|
||||
or use the updated template:
|
||||
```
|
||||
undercloud_install_script: undercloud-deploy.sh.j2
|
||||
```
|
||||
|
||||
Note, it is important to change the default value for the ``undercloud_install_script``
|
||||
to switch from the classic 'install' to the experimental 'deploy' method.
|
||||
|
||||
Secondly, you may want to refer an unpackaged t-h-t change refspec or a dev
|
||||
branch. To do so, override the custom t-h-t repo and branch/refspec
|
||||
for t-h-t templates to be fetched, for example:
|
||||
|
||||
```yaml
|
||||
overcloud_templates_repo: https://github.com/johndoe/tripleo-heat-templates
|
||||
overcloud_templates_branch: dev
|
||||
```
|
||||
|
||||
Note, these vars are shared with the overcloud role vars and point to
|
||||
the same templates path, branch/refspec and repo. The templates path should be
|
||||
R/W accessible by the given `non_root_user` without sudoing. So it is better
|
||||
off using the home dir or tmp dirs with sticky bits.
|
||||
|
||||
Also note that you should normaly rely on the openstack-tripleo-heat-templates
|
||||
package. The custom t-h-t repo vars may break that package and should be used with
|
||||
caution.
|
||||
|
||||
Note, checkout/install steps for the remaining yet unpackaged custom changes
|
||||
like dev branches for puppet modules, tripleo client, heat agent hooks, need
|
||||
to be covered in the custom ``undercloud-install.sh`` script body (rendered
|
||||
from a given in the ``undercloud_install_script`` template file name).
|
||||
|
||||
The last step is to define the ``undercloud_extra_args`` as needed. For
|
||||
example you may want to deploy:
|
||||
|
||||
* an optional non containerized Octavia,
|
||||
* containerized Keystone,
|
||||
* optional containerized Etcd,
|
||||
|
||||
with disabled telemetry, default docker images from `docker.io` namespace,
|
||||
debug logs for services and puppet, given a decent timeout, and keeping
|
||||
the ephemeral undercloud heat agent running for debug purposes:
|
||||
|
||||
```yaml
|
||||
undercloud_custom_env_files: >-
|
||||
{{undercloud_templates_path}}/environments/disable-telemetry.yaml
|
||||
{{undercloud_templates_path}}/environments/docker-minimal.yaml
|
||||
{{undercloud_templates_path}}/environments/services/etcd.yaml
|
||||
{{undercloud_templates_path}}/environments/services/octavia.yaml
|
||||
{{undercloud_templates_path}}/environments/debug.yaml
|
||||
{{undercloud_templates_path}}/environments/config-debug.yaml
|
||||
undercloud_extra_args: >-
|
||||
--timeout 60
|
||||
```
|
||||
|
||||
Where the t-h-t's `environments/docker-minimal.yaml` is like:
|
||||
|
||||
```
|
||||
resource_registry:
|
||||
OS::TripleO::Services::Docker: ../puppet/services/docker.yaml
|
||||
OS::TripleO::Services::Keystone: ../docker/services/keystone.yaml
|
||||
OS::TripleO::PostDeploySteps: ../docker/post.yaml
|
||||
OS::TripleO::PostUpgradeSteps: ../docker/post-upgrade.yaml
|
||||
OS::TripleO::Services: ../docker/services/services.yaml
|
||||
|
||||
parameter_defaults:
|
||||
DockerNamespace: tripleomaster
|
||||
ComputeServices: {}
|
||||
SwiftCeilometerPipelineEnabled: false
|
||||
```
|
||||
|
||||
Note, this template complements the default t-h-t's `environments/docker.yaml`
|
||||
setup that deploys everything in containers. The default template for
|
||||
the ``undercloud-install.sh`` also provides an additional set of required
|
||||
services used for undercloud to deploy overclouds (Ironic, Zaqar, MongoDB,
|
||||
Mistral). If you need a lightweight undercloud, make sure your custom
|
||||
undercloud installation script template omits those services and the
|
||||
`environments/docker.yaml` defaults.
|
||||
|
||||
You may also override ``undercloud_roles_data`` with a custom roles file
|
||||
(the path must be relative to the t-h-t templates ``undercloud_templates_path``).
|
||||
For the example above, custom undercloud roles may look like:
|
||||
|
||||
```
|
||||
- name: Undercloud
|
||||
CountDefault: 1
|
||||
disable_constraints: True
|
||||
tags:
|
||||
- primary
|
||||
- controller
|
||||
ServicesDefault:
|
||||
- OS::TripleO::Services::Etcd
|
||||
- OS::TripleO::Services::Keystone
|
||||
- OS::TripleO::Services::OctaviaApi
|
||||
- OS::TripleO::Services::OctaviaHealthManager
|
||||
- OS::TripleO::Services::OctaviaHousekeeping
|
||||
- OS::TripleO::Services::OctaviaWorker
|
||||
```
|
||||
|
||||
And an example playbook to call the role is:
|
||||
|
||||
```yaml
|
||||
# Deploy the undercloud
|
||||
- name: Deploy undercloud (experimental)
|
||||
hosts: undercloud
|
||||
gather_facts: false
|
||||
vars:
|
||||
containerized_undercloud: true
|
||||
undercloud_install_script: undercloud-deploy.sh.j2
|
||||
overcloud_templates_repo: https://github.com/johndoe/tripleo-heat-templates
|
||||
overcloud_templates_branch: dev
|
||||
undercloud_custom_env_files: >-
|
||||
{{undercloud_templates_path}}/environments/disable-telemetry.yaml
|
||||
{{undercloud_templates_path}}/environments/docker-minimal.yaml
|
||||
{{undercloud_templates_path}}/environments/services/etcd.yaml
|
||||
{{undercloud_templates_path}}/environments/services/octavia.yaml
|
||||
{{undercloud_templates_path}}/environments/debug.yaml
|
||||
{{undercloud_templates_path}}/environments/config-debug.yaml
|
||||
undercloud_extra_args: >-
|
||||
--timeout 60
|
||||
roles:
|
||||
- undercloud-deploy
|
||||
```
|
||||
``
|
||||
|
|
|
@ -1,85 +0,0 @@
|
|||
#!/bin/bash
|
||||
|
||||
set -eux
|
||||
|
||||
### --start_docs
|
||||
## Deploying the undercloud
|
||||
## ========================
|
||||
|
||||
## .. note:: In progress documentation is available at https://github.com/dprince/undercloud_containers/blob/master/doit.sh
|
||||
## ::
|
||||
|
||||
## * Export the required environment variables.
|
||||
## ::
|
||||
|
||||
{% for var in (undercloud_env_vars|default([])) %}
|
||||
export {{ var }}
|
||||
{% endfor %}
|
||||
|
||||
## * Set the local ip used for the undercloud install
|
||||
## ::
|
||||
|
||||
undercloud_local_ip={{ hostvars['undercloud'].undercloud_ip }}
|
||||
|
||||
## * Deploy the undercloud
|
||||
## ::
|
||||
|
||||
{% if release in ['pike', 'queens'] -%}
|
||||
{%- set env_files_path='services-docker' -%}
|
||||
{%- else -%}
|
||||
{%- set env_files_path='services' -%}
|
||||
{%- endif %}
|
||||
|
||||
sudo openstack undercloud deploy \
|
||||
--heat-native \
|
||||
--templates={{ undercloud_templates_path }} \
|
||||
--local-ip=$undercloud_local_ip \
|
||||
{% if undercloud_cloud_domain is defined %}
|
||||
--local-domain={{ undercloud_cloud_domain }} \
|
||||
{% endif %}
|
||||
{% if containerized_undercloud|bool %}
|
||||
{% if undercloud_enable_mistral|bool %}
|
||||
-e {{ undercloud_templates_path }}/environments/{{ env_files_path }}/mistral.yaml \
|
||||
{% endif %}
|
||||
{% if undercloud_enable_tempest|bool %}
|
||||
-e {{ undercloud_templates_path }}/environments/{{ env_files_path }}/tempest.yaml \
|
||||
{% endif %}
|
||||
{% if undercloud_enable_ironic|bool %}
|
||||
-e {{ undercloud_templates_path }}/environments/{{ env_files_path }}/ironic.yaml \
|
||||
{% endif %}
|
||||
{% if undercloud_enable_ironic_inspector|bool %}
|
||||
-e {{ undercloud_templates_path }}/environments/{{ env_files_path }}/ironic-inspector.yaml \
|
||||
{% endif %}
|
||||
{% if undercloud_enable_zaqar|bool %}
|
||||
-e {{ undercloud_templates_path }}/environments/{{ env_files_path }}/zaqar.yaml \
|
||||
{% endif %}
|
||||
{% if undercloud_generate_service_certificate is defined %}
|
||||
-e {{ undercloud_templates_path }}/environments/{{ env_files_path }}/undercloud-haproxy.yaml \
|
||||
-e {{ undercloud_templates_path }}/environments/{{ env_files_path }}/undercloud-keepalived.yaml \
|
||||
{% endif %}
|
||||
{% if undercloud_enable_telemetry|bool %}
|
||||
-e {{ undercloud_templates_path }}/environments/{{ env_files_path }}/undercloud-gnocchi.yaml \
|
||||
-e {{ undercloud_templates_path }}/environments/{{ env_files_path }}/undercloud-aodh.yaml \
|
||||
-e {{ undercloud_templates_path }}/environments/{{ env_files_path }}/undercloud-panko.yaml \
|
||||
-e {{ undercloud_templates_path }}/environments/{{ env_files_path }}/undercloud-ceilometer.yaml \
|
||||
{% endif %}
|
||||
{% if release in ['pike', 'queens', 'rocky'] %}
|
||||
-e {{ undercloud_templates_path }}/environments/docker.yaml \
|
||||
{% endif %}
|
||||
-e {{ working_dir }}/undercloud-containers-default-parameters.yaml \
|
||||
-e {{ working_dir }}/undercloud-parameter-defaults.yaml \
|
||||
{% endif %}
|
||||
{% if undercloud_custom_env_files is defined %}
|
||||
{% for f in undercloud_custom_env_files.split() %}
|
||||
-e {{ f }} \
|
||||
{% endfor %}
|
||||
{% endif %}
|
||||
{% if release not in ['pike', 'queens'] and undercloud_roles_data is defined -%}
|
||||
-r {{undercloud_roles_data}} \
|
||||
{% endif %}
|
||||
{% if undercloud_extra_args %}
|
||||
{{ undercloud_extra_args }} \
|
||||
{% endif %}
|
||||
-e {{ working_dir }}/hieradata-overrides-t-h-t-undercloud.yaml
|
||||
|
||||
### --stop_docs
|
Loading…
Reference in New Issue