205 Commits

Author SHA1 Message Date
Zuul
fde4f2112d Merge "Handle external ceph configs as templates" 2018-03-13 07:42:28 +00:00
Zuul
9275ba878f Merge "FIX inject password error" 2018-03-12 14:27:32 +00:00
Christian Berendt
fcf755c8ce Handle external ceph configs as templates
Change-Id: Ice5b058fe17ad7d648f21d1ddacaa339c6f7102f
2018-03-06 18:47:42 +01:00
Jianghua Wang
65fa37fb84 XenAPI: centralize the facts files
When bootstrap compute hosts for XenAPI, it will generate a facts
file for each compute node. It contains some XenAPI specific variables
for both the compute host and the XenServer where the compute host
run on. This commit is to fetch the facts file into deployment host
and put it under a centralized directory - each compute host will
have a separate sub-dir which is named with its *inventory_hostname*.

In this way, the following tasks can use proper variable from the
proper facts file which exactly belongs to the host they running on.

Change-Id: I68d1a2d098d38c8e6bf4db76cdaf1f0465831822
blueprint: xenserver-support
2018-03-05 13:57:15 +00:00
Dai Dang Van
d77930373e Support policy.yaml file [part 2]
- Keystone
- Glance
- Nova
- Cinder

This will copy only yaml or json policy file if they exist.

Change-Id: I4a9415d82322aed68c9b7650bdf346f58fa49e2a
Implements: blueprint support-custom-policy-yaml
Co-authored-By: Duong Ha-Quang <duonghq@vn.fujitsu.com>
2018-01-29 13:35:59 +00:00
Alexandru Bogdan Pica
8e3b79440c Implement external MariaDB and pre-configured Databases support
This change allows the following use cases:

1. Using an already-configured MariaDB / MySQL server / Cluster
2. Using already-created DB users, without requiring root DB access.

Update: added external mariadb precheck

Change-Id: I78b0d178306d7c5293b0bf53e445f19f18b4b824
Implements: blueprint external-mariadb-support.
Closes-Bug: #1603121
2018-01-23 13:07:40 +00:00
Jianghua Wang
b2c7269ee7 XenAPI: Support compute node bootstrap
This is to add a bootstrap task for XenAPI to bootstrap the compute
node. One compute node is composed with a XenServer and a DomU VM
running on the XenServer. Before it's ready for deploying OpenStack
sevices on it, we need bootstrap it firstly. The package of
python-os-xenapi contains a tool and some utils which were developed
to finish all of the needed bootstrap tasks
e.g.:
1. configure himn(host internal management network)
2. configure ipatables to allow traffic
3. install xapi plugins to dom0
4. gather XenAPI facts and save them into a file
...

The task added in this commit is to invoke that tool so that the
bootstrap tasks can be completed automatically during kolla deployment.

Depends-On: Ie2d7d40f2755580aac4a10f3d302190a8bd4fe6f
Change-Id: I1500535a1c9a085bcbfec5db5fbddcf040e6892d
blueprint: xenserver-support
2018-01-19 10:59:11 +00:00
Zhaokun Fu
93fcfe7134 FIX inject password error
The envirenment variable LIBGUESTFS_BACKEND = direct
is not enabled by default in docker container.
Without it, GuestFS() init failed.

Closes-Bug: #1742029

Change-Id: I24330502df7abc8e8f952ebb41bd9ae5e4ba1168
2018-01-12 07:54:59 +00:00
Zuul
89d5a24ad1 Merge "Allow empty compute group when ironic is in use" 2017-12-29 08:20:19 +00:00
Mark Goddard
d8a744e436 Allow empty compute group when ironic is in use
If ironic is in use it is valid to have no (virtualised) compute nodes.

Change-Id: I100540fbfd81be5642c1d4ed135fcd500924a47e
Closes-Bug: #1701317
2017-12-19 10:47:33 +00:00
Zuul
df4641b547 Merge "Remove the unnecessary register.yml from upgrade.yml for Nova" 2017-12-15 03:05:36 +00:00
caoyuan
b1c15af95d Remove the unnecessary register.yml from upgrade.yml for Nova
upgrade action no need to create endpoint, project, user, and role.
so the register.yml is unnecessary for upgrade.yml. this patch to
remove it.

Change-Id: I7e8d2c03cc596a551cd3e4b9b5214098d666f7ca
Closes-Bug: #1737071
Co-Authored-By: chenqiaomin <chen.qiaomin@99cloud.net>
2017-12-08 07:09:10 +00:00
Christian Berendt
6039ad46f9 Restart services after a change in the external ceph configuration
Change-Id: I6b6114e85a4df82458c441f471929513c2526c23
2017-11-02 08:43:43 +01:00
Duong Ha-Quang
2d3866c6a4 Specify 'become' for only necessary tasks (default roles)
Add become to only neccesary tasks in roles:
- glance
- heat
- horizon
- keystone
- neutron
- nova
- openvswitch

Gate is also updated to use 'become' feature

Change-Id: I2f3f27306e9f384148e1ad4d54d8da2ebef34d00
Partial-Implements: blueprint ansible-specific-task-become
2017-10-31 02:55:31 +00:00
Eduardo Gonzalez
56374206be Fix deployment with public TLS enabled
When deploying with tls enabled in public
endpoints, ansible modules fails due SSL certificates
are self-signed.

This change adds a new variable to allow customization
on which endpoints ansible should connect.
Defaults to admin because admin auth parameters defaults
to admin endpoint.

Change-Id: Ic3ed58cf9c9579cae08a11bbfe6fce983b5a9cbc
Closes-Bug: #1720995
2017-10-05 08:36:34 +00:00
Jenkins
9cdbae707b Merge "Simplify Openstack services configuration possibilities" 2017-09-26 15:49:22 +00:00
Jenkins
1b9acf0663 Merge "Make the pg and pgp value configurable" 2017-09-25 11:27:25 +00:00
caoyuan
8fed5e2e62 Make the pg and pgp value configurable
Change-Id: I99cca8c3830077736f71a7ab1abd3818688f9bb1
2017-09-22 03:21:52 +00:00
Bertrand Lallau
a3dfdfc085 Simplify Openstack services configuration possibilities
Actually Openstack services configuration can be overriden using many
files:
- /etc/kolla/config/<< service name >>/<< config file >>
- /etc/kolla/config/<< service name >>/<<host>>/<< config file >>
- /etc/kolla/config/global.conf
- /etc/kolla/config/database.conf
- /etc/kolla/config/messaging.conf

Only per-service configuration is actually documented here:
https://github.com/openstack/kolla-ansible/blob/master/doc/advanced-configuration.rst#L164

Allowing to globally modify service configuration can be perform too,
but it can be done in 3 different manners, all not documented:
- /etc/kolla/config/global.conf
- /etc/kolla/config/database.conf
- /etc/kolla/config/messaging.conf

database.conf and messaging.conf seems redundant with global.conf.
In order to simplify codebase it seems logical to remove them.

Documentation has been added for overriding configuration globally and
release note has been added too.

Closes-Bug: #1682479
Change-Id: I5d922dfc0d938173bad34ac64e490b78db1b7e31
2017-09-13 17:47:36 +02:00
Jeffrey Zhang
5937724503 Add ipc_mode=host for nova-compute conainer
ipc_mode=host is required after enabled multipath in nova.

Closes-Bug: #1713639
Depends-On: I0a1d85597999415cab11feb71a7fdfd7af3f7148
Change-Id: Ib0b8961a47b686b6c35456768bbbccc741cb7adf
2017-08-29 15:27:34 +08:00
Jenkins
3393054f9b Merge "Add vSphere support to nova_compute" 2017-08-15 14:44:06 +00:00
Christian Berendt
7f4742ff4b Unify external_ceph.yml filename
It is external_ceph.yml for cinder/glance/gnocchi.

Change-Id: I534bffe5fc914e2850fb5cb5719fd99afa06c6c4
2017-08-07 10:44:54 +02:00
guochao
c9eaf9158b Add vSphere support to nova_compute
Implements compute part of the blueprint.
Make virt_type of nova_compute configerable.

Change-Id: I0f37e49e09c4f14a64797506007bb55a6f534f0f
Partially-implements: blueprint kolla-ansible-support-vsphere
Co-Authored-By: shaofeng cheng <chengsf@winhong.com>
2017-08-04 17:15:57 +08:00
Jenkins
00e3d2f805 Merge "Pull cinder cephx keyring only when enable_cinder is true in nova" 2017-07-14 13:11:10 +00:00
Jeffrey Zhang
6a12fd8a85 Pull cinder cephx keyring only when enable_cinder is true in nova
cinder_backup_ceph is true in default when enable_ceph is true.

Change-Id: Ic3cbd041a784610323cda4419acb6702f2aa35c1
Closes-Bug: #1699658
2017-07-14 10:05:32 +08:00
Jenkins
c88b9eb40e Merge "Clean some Boolean condition checks" 2017-07-13 08:48:44 +00:00
Jenkins
a71aa61ea7 Merge "Use unified vars in task" 2017-07-12 01:56:12 +00:00
Bertrand Lallau
8b5b3cef4e Clean some Boolean condition checks
* "bool" filter is removed when not required
* 'not' is used instead of '== False' check

Change-Id: I85a5bb9a5ea874ac1c397cbf8de416147d2424c3
2017-07-10 15:00:28 +00:00
Bertrand Lallau
a9113fc466 Avoid launching "local" actions too many times
In order to speed up deployment time some "local" actions should be run
only once using 'run_once: True'.
This will decrease deployment time in case of multihost configuration.

Change-Id: I6015d772d35c15e96c52f577013b6e41197cb41a
2017-07-05 15:55:39 +02:00
Jenkins
19c1bc7f88 Merge "Remove symlink in reconfigure tasks" 2017-07-04 03:11:37 +00:00
Eduardo Gonzalez
8d5526c070 Remove symlink in reconfigure tasks
Some roles have a symlink to deploy.yml file
for reconfigure. This is causing some issues.
"included task files must contain a list of tasks"

Change-Id: Ie7ade52900a61bc1c5b867fa7a8f75fc541a6426
Closes-Bug: #1694251
2017-07-03 09:34:21 +00:00
Jenkins
f2f3104e9f Merge "Fix the database user name for all roles" 2017-07-01 00:41:49 +00:00
Jeffrey Zhang
a1f42ad38a Pull cinder cephx keyring only when cinder_backup_ceph is true in nova
Change-Id: Ia766c1aa60d51fbff2c620394474597a7146b9cc
Closes-Bug: #1699658
2017-06-22 12:39:36 +08:00
caoyuan
36c530f9ed Fix the database user name for all roles
when create database user, it should use
database_user, not database_name.

Change-Id: I4dfa01d1a5a46c5c58f1fc47b0be71b186462764
Closes-Bug: #1698762
2017-06-20 21:19:31 +08:00
Jeffrey Zhang
03e1b05f99 Use unified vars in task
Ansible task support vars directive, no need implement another one in
merge_config. This patch remove the vars directive in merge_config
action plugin.

Change-Id: I33648a2b6e39b4d49ce76eb66fbf2522721f8c68
2017-06-15 22:37:28 +08:00
Jenkins
b62e1d9574 Merge "Add the ceph keyring files related task condition" 2017-06-12 09:32:10 +00:00
Jenkins
3a68aee3ad Merge "Use auth vars for admin user" 2017-06-04 15:05:29 +00:00
Bertrand Lallau
afdd11b9a2 Generalize api_interface_address variable usage
Useful api_interface_address variable has been define here:
https://github.com/openstack/kolla-ansible/blob/master/ansible/group_vars/all.yml#L57
In order to simplify codebase we must use it as much as possible.

Change-Id: I18fec19bf69e05a22a4142a9cd1165eccd022455
2017-05-23 08:35:15 +00:00
Eduardo Gonzalez
e9bde0dcb9 Use auth vars for admin user
In someplace in the code admin user, project and domain name
are hardcoded.

This change use the correct variable defined at:
https://github.com/openstack/kolla-ansible/blob/master/ansible/group_vars/all.yml#L278

Change-Id: I3a4c78d81733bf7a2f3c67d259ec5c5f5bb38d3f
2017-05-16 08:54:37 +00:00
Jeffrey Zhang
b1f015616c Add timeout parameter for precheck tasks
wait_for module waits 300 seconds for the port started or stopped.  This
is meaningless and useless in precheck. This patch change timeout to 1
seconds.

Change-Id: I9b251ec4ba17ce446655917e8ef5e152ef947298
Closes-Bug: #1688152
2017-05-04 09:02:25 +08:00
Jenkins
defc49448b Merge "Add compute inventory precheck" 2017-05-02 08:05:17 +00:00
Eduardo Gonzalez
fee4eee0be Add compute inventory precheck
With nova cells_v2 at least one compute node is required in
inventory to deploy nova.

This change add prechecks to ensure at least 1 compute is present.

Change-Id: I242518ad3bd149ad245515299301777f6b3bdd08
Closes-Bug: #1686410
2017-04-26 16:18:15 +02:00
shaofeng_cheng
12621ef8f1 Add the ceph keyring files related task condition
If used external ceph for nova,the ceph storage not enable cephx.
So ceph keyring file not does not exist.
Task throw error of check ceph keyring files.

Change-Id: I6257c107b94abf4d363e854229aaab8301d1d694
Closes-Bug: #1684522
2017-04-21 10:06:04 +08:00
Eduardo Gonzalez
5dfb81efc8 Update simple_cell_setup to manual creation
Simple_cell_setup is not recomended to use.
Is better create map_cell0 manually, create base
cell for non cell deployments and run discover_hosts.

This PS migrate actual config to make use of described
workflow at [1]. We our actual workflow we're running
into the issue that services are not mapped until cells
are present, breaking deployment waiting for compute
services to appear.

[1] https://docs.openstack.org/developer/nova/cells.html#fresh-install

Change-Id: Id061e8039e72de77a04c51657705457193da2d0f
Closes-Bug: #1682060
2017-04-18 12:09:13 +01:00
Bertrand Lallau
3170b6c2a7 Fix 'node_config_directory' variable bad usage
Some roles made a bad usage of the 'node_config_directory' variable.

As described here:
https://github.com/openstack/kolla-ansible/blob/master/ansible/group_vars/all.yml#L16

'node_config_directory' is the directory to store the config files on
the destination node.

This variable MUST be changed to 'node_custom_config'.
Futhermore this will unified all roles.

Closes-Bug: #1682445
Change-Id: Id8d8a1268c79befac8938c1e0396267314b40301
2017-04-13 17:15:24 +02:00
Eduardo Gonzalez
de4747afae Temporaly fix deploy gate
Nova service-list is returning empty registered service
when in database they are. Because of this, simple_cell_setup
is not executed and deploy stucks waiting for nova-compute.

This change temporaly checks the database for existing nova services
instead of openstack compute service list.

This change will need to be reverted once the command is fixed.

Change-Id: Ic508eb3ff03b5f233186353fc7697305cc792d14
2017-04-11 18:10:06 +01:00
caoyuan
312c3fe56f Fix the Nova SSH port prechecks missing
Change-Id: Ide78ed1de89a9904db48f08fcff3c247ee650317
2017-03-19 16:55:58 +08:00
Jenkins
9e804f4286 Merge "Multi-regions Support" 2017-03-16 17:42:07 +00:00
Nathan Harper
586e81f39e Nova external-ceph.yml writes keyname into libvirt.base64
Closes-Bug: #1671862
Change-Id: I6b77773238cd65a3cc009d8d9a38bdbea0035212
2017-03-14 08:53:28 +00:00
rcherrueau
dcdbe44190
Multi-regions Support
Add support for basic multiple regions, that is to say, many OpenStack
with a shared Keystone (same users) and Horizon. The shared Keystone
and Horizon are deployed into one region, for instance RegionOne.
Services of other regions have an access to this Keystone. This
support assumes that the operator knows the name of all OpenStack
regions in advance, and considers as many Kolla runs as there are
regions.

The new variable, multiple_regions_names, contains the name of
regions. It is needed by the region that includes Keystone and
Horizon. In register.yml, it specifies to create as many Keystone
endpoints as there are regiones, so that services of other regions can
connect to Keystone. In local_settings.j2, it changes the render to
support multiple regions in Horizon. The multi-regions.rst explains
how to perform a multiple regions deployment.

Implements: blueprint multi-kolla-config
Change-Id: Icab2aebfc4de0e3bc609950956e0af397705f403
2017-03-10 14:24:42 +01:00