164 Commits

Author SHA1 Message Date
Jeffrey Zhang
84ade4e149 Remove useless module_extra_vars in registry.yml
- remove uesless module_extra_vars, this is a historical issue. In the
  past, we use 'docker exec kolla_toolbox ansible xxx' to run module on
  target node, so complex data have to pass through extra_vars. Now we
  are using kolla_toolbox module, no need to use extra_vars anymore.
- Remove some useless until.

Change-Id: I72ed28001202917f9a82a1c3ea33cd6319911ec8
2018-04-16 09:14:54 +08:00
Eduardo Gonzalez
418cb52767 Support extra ml2 plugins in neutron
Add support to use custom/extra ml2 plugins for vendor
drivers.

Change-Id: I8586c447dc3b91357b2eecb7a9c4724e033e595f
2018-04-12 09:17:48 +02:00
Vladislav Belogrudov
1c1d6e20c1 Introduce variable to allow different DVR modes
This feature replaces splitting of compute hosts into inner
and external with a new variable 'neutron_compute_dvr_mode'
that controls whether computes will have full-blown DVR or
internal only (tenant) networking.

Change-Id: I6720ccfcfcec89f9996d4cb5ae60f31eb3113667
Implements: blueprint dvr-mode-property
2018-04-03 19:14:14 +03:00
Eduardo Gonzalez
ea1a1dee0d Verify YAML syntax in gates
This patchset implements yamllint test to all *.yml
files.

Also fixes syntax errors to make jobs to pass.

Change-Id: I3186adf9835b4d0cada272d156b17d1bc9c2b799
2018-03-26 17:56:22 +02: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
Christopher Nipper
6bb27ac06f Add support for Neutron SRIOV agent container
Agent is required for Neutron SRIOV post Mitaka
Closes-Bug: #1655921

Addressed comments
Added release notes

Change-Id: Ib8181c4da65fccd0c5f8487217060e5682977665
Signed-off-by: Christopher Nipper <christopher.r.nipper@intel.com>
2018-01-24 17:12:36 +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
0df6e2046e XenAPI: Support neutron configuration
When using XenAPI as the compute virt driver, we need an OVS agent
to manage the OVS running in XenServer dom0. This OVS agent uses
the HIMN(Host Internal Management Network) to communicate with
dom0's OVS. This commit includes the following changes:

* Add a new ovs agent service - neutron-openvswitch-agent-xenapi
  This new agent service will run in the compute hosts and controls
  the OVS running in XenServer dom0; the existing agent service -
  neutron-openvswitch-agent will run in the network hosts and controls
  the OVS running in network hosts.

* It retrieves XenAPI variables from the json file generated at XenAPI
  bootstrap.

* Basing on the XenAPI variables, it will customize relative ml2_conf.ini's
  configure options in a new template which will override the default options.
  e.g.
  * of_listen_address:
  XenAPI use the local himn interface's IP as of_listen_address, so
  that the ovs running dom0 can receive OpenFlow rules from the service
  of neutron-openvswitch-agent-xenapi.
  * ovsdb_connection:
  XenAPI use XenServer dom0's HIMN IP as the OVS DB connection IP, so
  that neutron-openvswitch-agent-xenapi can connect to dom0's OVS DB.
  * host:
  Use the dom0's hostname.

* At the moment, l2_population doesn't for for XenAPI. So disable it.

References:

* XenServer (and other XAPI based Xen variants):
  https://docs.openstack.org/nova/pike/admin/configuration/hypervisor-xen-api.html

* XenCenter HIMN plugin (adding HIMN network which is used by XenAPI driver to
  communicate with XenServer):
  https://github.com/citrix-openstack/xencenter-himn-plugin

* Neutron OVS agent configuration options:
  https://docs.openstack.org/neutron/latest/configuration/openvswitch-agent.html

Change-Id: Iaee0a6c84069b3e6015b00de7aea880cdd33ab09
blueprint: xenserver-support
2018-01-19 10:59:49 +00:00
Mathieu Rohon
fc593d531b missing permissions when running as non root
some tasks miss permissions to be run as a normal user

Change-Id: Ic53308adb7fa3a10a7b1f1caa27ca7dd67037cdd
2017-12-12 16:51:36 +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
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
Bertrand Lallau
41d4d7bcaf Clean Boolean condition check on exists check
"bool" filter is not required cause exists return Boolean

Change-Id: I5fa53ec1ebba14ebb8ed3d3d75ae4fb0c6666c44
2017-09-01 09:44:22 +02:00
shaofeng_cheng
9ea1b06bfa Remove service_providers in vpnaas_agent.ini
Service_providers config group is already configured in the neutron_vpnaas.conf.
So, we only need to load the neutron_vpnaas.conf configuration file
when the neutron_vpnaas_agent container starts, without having
to duplicate the configuration.

Change-Id: I7b78831325db4bbb263b2cc174e848ea7037ad0a
2017-08-13 10:41:11 +08:00
Jenkins
89a55b4f44 Merge "Clear all l3 related namespace before starting neutron-l3-agent" 2017-08-11 11:16:43 +00:00
guochao
70ca560322 Add vmware DVS support to kolla-ansible
Openstack is able to simply manage VLAN network on VMware
Distributed Switch.
DHCP agent can provide dhcp offer with vlan tag provided
by OVS.
Both neutron external nic and physical nic of vCenter/
vSphere should be on a vlan trunk port and can communicate
with each other.

Depends-On: I4655086a3f058ec769d3d37ec6a19565b5ea0841
Change-Id: I6d1629e93f0efeddd2a9000f66cc6f714bebb07c
Partially-implements: blueprint kolla-ansible-support-vsphere
2017-07-24 05:42:14 +00:00
Eduardo Gonzalez
d4e7dfb376 Finish/fix neutron sfc service
Neutron-sfc-agent start its functions with openvswitch.
This change moves sfc configuration into neutron-openvswitch-agent.

Rework config files to use openvswitch when sfc or openvswitch
are used as network plugin.

Also adds sfc extension_driver to ml2

Change-Id: If1ebf9554f6d686cc6d064e698a48f8a6b6172b3
Closes-Bug: #1664493
Depends-On: I60ba1333231a4ae38a041d41e551f7d74fe15e3b
2017-07-19 09:06:24 +01:00
Jenkins
d5c6689629 Merge "Fix fwaas options" 2017-07-14 13:17:42 +00:00
Jenkins
a71aa61ea7 Merge "Use unified vars in task" 2017-07-12 01:56:12 +00:00
Jenkins
0572a394be Merge "Avoid launching "local" actions too many times" 2017-07-10 13:40:49 +00:00
Jeffrey Zhang
58964d6825 Clear all l3 related namespace before starting neutron-l3-agent
Remove all l3 related namespaces in case of multiple active routers in
l3 high available mode. The root cause is that keepalived does not
remove the vip address from nic during starting.

neutron-vpnaas-agent is subclass of l3 agent, so should remove all l3
related namespace before starting vpnaas agent.

Closes-Bug: #1703078
Depends-On: Ic9417d2eb03e0dd93f7c668b189b4ad9c72eae0f
Change-Id: I05c1faf2551bb5e70c299e884adf58cd2af52739
2017-07-10 11:53:13 +08:00
jimmygc
865736c21d Fix fwaas options
fwaas is in pending create state when I attach it to a router.
This patch fix this.

Change-Id: I18b56ed3698e22a02a8718b39360fde76c12428b
Closes-Bug: #1689703
2017-07-07 13:00:02 +08:00
Jenkins
7c789a662c Merge "Add VMware NSXV support to neutron" 2017-07-06 22:46:39 +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
Vladislav Belogrudov
296ddbeb03 Add possibility to configure tenant network types and type drivers
This patch add configuration options for tenant network types and type
drivers. Both lists are checked so that tenant types are listed in
drivers. For ironic 'flat' driver is mandatory and is added explicitly
into ironic prechecks.

Change-Id: Ie5775001165412910a258cbed2d2ebbb8ebbd879
Closes-Bug: #1694725
2017-06-21 17:14:25 +03: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
jimmygc
8d1b745f45 Add VMware NSXV support to neutron
Implements NSXV network part of  the blueprint.

Change-Id: I6b92b946667ebbbd2721a99fd299981cfc99693f
Partially-implements: blueprint kolla-ansible-support-vsphere
Co-Authored-By: shaofeng cheng <chengsf@winhong.com>
2017-06-12 09:51:23 +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
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
Bertrand Lallau
5fe11a8fcb Fix neutron agents restarted on ml2 config change
The following Neutron agents:
- neutron-metadata
- neutron-dhcp-agent
- neutron-l3-agent
- neutron-lbaasv2-agent
- neutron-vpn-agent
doesn't require ml2_conf.ini file.
ml2_conf.ini file is used to managed L2 network configuration.
This config doesn't have to be in DHCP, L3, metadata agents...

We should remove it to avoid restarting these agents in case of
ml2_conf.ini file modification.
Only neutron-server, neutron-openvswitch-agent,
neutron-linuxbridge-agent must be restarted.

Closes-Bug: #1677163
Change-Id: I0876b8a3845d1c2bccd996426a65df1a3a6f7085
2017-04-26 14:26:21 +00:00
zhangdongqi
e082217727 neutron_vpnaas_agent: kolla_docker parameter 'volumes' is wrong
In task "Running Neutron vpnaas bootstrap container",
parameter "volumes" of kolla_docker should be
"{{ neutron_vpnaas_agent.volumes }}"
NOT
"{{ neutron_vpnaas_agent.image }}"

Change-Id: Id7c95d4d6f53dfab384e387951eecf4d87459de
Closes-Bug: #1683669
2017-04-18 22:14:56 +08: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
Bertrand Lallau
74dfe047b8 Remove Ubuntu 14.04 related code
Last Openstack version supported on Ubuntu 14.04 is Mitaka.
Hence Ubuntu 14.04 related code can be safely remove from Ansible tasks
since Kolla Newton release.

Change-Id: I7202c1f6d21a2e6f3536c0420a7cc889aff0f5ed
2017-03-24 13:22:12 +01:00
Bertrand Lallau
cbe374ce30 Use service_name variable when defined in neutron role
service_name variable is defined in tasks but not used everywhere.

Change-Id: I67a95f49d277cf004338a9c184e7be70608714b7
2017-03-21 21:35:02 +00:00
Thomas O'Neill
94dec80705 Add neutron-bgp-dragent playbooks and sensible defaults.
Depends-On: If7f5c80eb10a1c418785d9c659ae18bfecfcfe33
Change-Id: I9c54f01193b4e12338e71cd1f0a4635dcbfa43fe
Implements: blueprint neutron-bgp-dragent
2017-03-16 10:03:17 +00:00
Eduardo Gonzalez
55beaca4a4 Fix vpnaas custom config dir
node_custom_config is /etc/kolla/config
not need add config after.

Change-Id: Iac9747a705185e87b5e7d62856a9ada99f589078
Closes-Bug: #1671758
2017-03-10 09:29:14 +00:00
Jenkins
9d0daa015a Merge "Enable sanity checks from kolla-ansible" 2017-03-09 17:31:51 +00:00
Paul Bourke
5418ada148 Enable sanity checks from kolla-ansible
Add a new subcommand 'check' to kolla-ansible, used to run the
smoke/sanity checks.

Add stub files to all services that don't currently have checks.

Change-Id: I9f661c5fc51fd5b9b266f23f6c524884613dee48
Partially-implements: blueprint sanity-check-container
2017-03-09 10:37:06 +00:00
Jeffrey Zhang
47762d4850 Fix the failure when running precheck after deploy
* Move the tasks to the role
* Skip the task when container is already running

Change-Id: I1990d4dd2a02efa2b3766329000aa23419e0ff17
Closes-Bug: #1670286
2017-03-07 06:57:16 +00:00
Jenkins
d9740e9c40 Merge "Remove unnecessary until in register.yml file" 2017-02-22 12:28:06 +00:00
Jeffrey Zhang
a4beb63c20 Optimize reconfigure action for neutron
Partially-implements: blueprint better-reconfigure
Change-Id: I3879b9339b54e1d063dd1c4673bac85ced333335
2017-02-12 15:39:41 +00:00
Jeffrey Zhang
38ad05a872 Remove unnecessary until in register.yml file
Change-Id: I1577cc3afef4dadd3a188c8ba749c9cdfad313ae
2017-02-04 14:38:54 +08:00
Eduardo Gonzalez
4e0fa6a334 Remove hardcoded usernames in register.yml
Usernames can be configured with variables in
configuration files, but user creation is hardcoded.

Change-Id: I057cfb921d776217db66f59226dcfa79f3eb7368
Closes-Bug: #1661587
2017-02-03 12:17:54 +00:00
Eduardo Gonzalez
e50d5cbf4f Remove hardcode /etc/kolla path
Leaved vagrant and documentation harcoded
/etc/kolla paths due the nature of the files.

Change-Id: Id316980d3d4e8f3de98672d7ed258e0652ed7213
Closes-Bug: #1659771
2017-01-30 16:13:12 +00:00
Jeffrey Zhang
8155d74d8d Refactor register.yml files
Co-Authored-By: Mauricio Lima <mauriciolimab@gmail.com>
Change-Id: I9a4a6b6523dee4b388513386b7d85d421f2b7b89
2017-01-26 17:10:27 +00:00
Jenkins
3f8cb8adda Merge "Refactor bootstrap.yml file" 2017-01-18 10:17:50 +00:00