122 Commits

Author SHA1 Message Date
Paul Bourke
5cb375645c Add a Kolla 'devstack' mode
Add a new variable 'kolla_devmode', which when enabled, clones and
bindmounts service source code into the containers.

This commit adds the relevant changes for Heat, more services can be
added and built upon.

Usage:
* Set 'kolla_devmode: yes'

* Code is cloned to /opt/stack/{{ project_name }} on target
  node(s)

* Users can develop in these repos, and simply restart the container to
  pick up / test changes.

Debugging can be done from the host via 'remote_pdb'[0].

[0] https://pypi.python.org/pypi/remote-pdb

Implements: blueprint mount-sources
Change-Id: Ic0431b10d723bf84eeefc72039376fe0058dd902
2017-06-08 09:55:54 +01:00
Jenkins
dd11b3f5a4 Merge "Support OSprofile usage" 2017-06-05 08:54:43 +00:00
Jenkins
59da58f283 Merge "Mixing binary and source images for D*, G* and H* projects" 2017-06-05 02:09:18 +00:00
Jenkins
2065e4d059 Merge "Fix heat ec2 keystone auth" 2017-06-04 15:03:12 +00:00
Eduardo Gonzalez
ab4b1ff785 Support OSprofile usage
OSprofile allows user/devs trace OpenStack requests.

Implements: blueprint enable-osprofiler
Co-Authored-By: Bertrand Lallau <bertrand.lallau@gmail.com>
Change-Id: I82ea85d726011ef6cbf99380f395452d6d7f8053
2017-06-02 22:41:33 +02:00
Dai Dang Van
f127da3cb1 Mixing binary and source images for D*, G* and H* projects
In case Kolla's users want to deploy with both of
binary and source image, we should have a variable
install type that define install type for each project.

We also add specific image tag for each Openstack project.

This commit is implemented for Designate, Gnocchi and Heat projects.

Change-Id: I07451750e70e0e6305dca451422e33cd31ce8a4c
Implements: blueprint mixing-binary-and-source-image
2017-06-02 17:17:06 +07:00
Jenkins
94a9c9173a Merge "Advertise public heat endpoint for wait conditions" 2017-05-23 11:09:28 +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
shaofeng_cheng
a1606f875e Add heat_stack_owner role to admin project
The Orchestration service automatically assigns the heat_stack_user
role to users that it creates during stack deployment.
To avoid conflicts, do not add this role to users with the heat_stack_owner role.

Closes-Bug: #1690975

Change-Id: I7a4cb7f4a13de7be4fc9ce9c24057ece6a0ced5c
2017-05-17 17:16:17 +08:00
Eduardo Gonzalez
de31cdc77b Fix heat ec2 keystone auth
Heat-api-cfn need to point to keystone v3 version.
Otherwise heat fail while authenticating for scaling policies.

``AWS authentication failure.``

Change-Id: I1950cd7359d8ad589feced870de76f02ef2c8a76
Closes-Bug: #1672431
2017-05-05 08:05:33 +00:00
Mark Goddard
033308c475 Advertise public heat endpoint for wait conditions
Wait conditions are commonly used by instances to signal various events
back to heat. These instances are unlikely to have access to the
internal API endpoints. OpenStack-Ansible had a similar issue[1] back in
juno and changed to use the public endpoint[2]. The code has now moved
but the default is still in place[3].

This change configures heat to advertise the public API as the endpoint
for wait conditions.

[1] https://bugs.launchpad.net/openstack-ansible/+bug/1459414
[2] https://review.openstack.org/#/c/186221/
[3] b1721a7460/defaults/main.yml (L48)

Change-Id: Id1d66aaa298efa8407db579a899a5aacebe1e6c7
Closes-Bug: #1688331
2017-05-04 18:54:34 +01: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
6d6d7b37fa Merge "Change heat cfn service description" 2017-04-05 15:46:58 +00:00
Jenkins
b46144573d Merge "Heat: add oslo_messaging_notifications config" 2017-03-29 01:56:40 +00:00
Bertrand Lallau
916a69c9fa Heat: add oslo_messaging_notifications config
Heat can send RPC notifications to Ceilometer as define here:
https://github.com/openstack/ceilometer/blob/master/ceilometer/pipeline/data/event_definitions.yaml#L139

oslo_messaging_notifications section MUST be managed in heat.conf file.

Closes-Bug: #1674935
Change-Id: I314e34a7a7b6caab72b916331f5f20c29afde438
2017-03-22 11:03:22 +01:00
Jenkins
ac2e9425b6 Merge "Enable heat-api proxy header parsing" 2017-03-20 16:38:34 +00:00
Eduardo Gonzalez
fccff019a6 Change heat cfn service description
While in openstack deployment guides use Orchestration as
heat-cfn description, heat devstack plugin uses CloudFormation.
I think is more accurate and easier to know which service is.

Change-Id: I760c7e7baa46da57fd2fca9d5409f370a0c9065c
Closes-Bug: #1673421
2017-03-16 11:04:58 +00:00
Bertrand Lallau
cb1d214d3e Fix heat-engine and heat-api-cfn workers configuration
Change-Id: I5c04712b1ae9ebe36b5c57eed05c34fec09f1fd8
Closes-Bug: #1671784
2017-03-10 15:49:28 +01: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
pomac
63e5c444dd Enable heat-api proxy header parsing
heat-api kept redirecting clients to use http:// instead of https://
when communicating with our https:// only loadbalancer

Please examine the logic for enabling it carefully, it's hard to know
if it should be enabled or not, potenitially it could be a security
risk.

Based on openstack-ansible-os_heat:
commit 4033a0f854cba6719c61812ef5b553e932a6c6c2
Author: Kyle L. Henderson <kyleh@us.ibm.com>

    Enable oslo_middleware proxy header parsing

"Heat has moved to using oslo_middleware for the http proxy header
parsing, however the default is to not parse the headers.  When
the external protocol differs from the internal protocol this
parsing is required in order for heat to work properly since it
will return 302 redirects to the client during some operations
(such as delete stack).

An example of this is when using haproxy with https configured
for the external protocol and http for the internal protocol.
If the oslo_middleware does not parse the headers, then any
302 redirects would specify a url with http rather than
correctly specifying https and the heat client would fail to
connect on the redirect url."

Change-Id: I38661a0bc2163a7f72febd98b7ae6f51c5d45ad5
2017-03-01 09:57:21 +01:00
Jenkins
d9740e9c40 Merge "Remove unnecessary until in register.yml file" 2017-02-22 12:28:06 +00:00
caoyuan
1c3c611f40 Add the missing condition for config.yml
- add "item.value.enabled | bool"
- add "| bool" to keystone
- add group check for searchlight

Change-Id: Id4555a0a96ea1670e99c88a1da9d3e07bf253497
2017-02-14 11:19:26 +08: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
Jenkins
8884422f3d Merge "Refactor register.yml files" 2017-01-26 18:48:59 +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
Farid Da Encarnacao
03a288ad4b Fix typo heat.conf
Change-Id: Icf34357d222cf5eb41e504c3b5e6830c1c6509c5
Closes-Bug: 1659343
2017-01-25 11:26:03 -05:00
Borne Mace
bb475911d3 Fixed config generation to check correct actions
A config generation check was added to a few services but the action
name checked was "genconfig" where the kolla-ansible genconfig command
actually uses the action name "config".

Stop run the handlers when action is "config".

Co-Authored-By: Jeffrey Zhang <jeffrey.zhang@99cloud.net>
Partially-implements: blueprint better-reconfigure
Change-Id: I9d3be2f674087f340108b176c8e8e2209ffa8806
2017-01-24 11:43:05 +08:00
caoyuan
a755e7f0a4 Optimize reconfiguration for heat
Change-Id: I0e8b16bba5c826a97a4e9bd07891f5f3fb549334
Partially-implements: blueprint better-reconfigure
2017-01-20 09:14:22 +00:00
Jenkins
3f8cb8adda Merge "Refactor bootstrap.yml file" 2017-01-18 10:17:50 +00:00
Jeffrey Zhang
7233b45d29 Refactor bootstrap.yml file
Change-Id: I00d2dcb0895548ba169ab85764cf546c2214cbf5
2017-01-12 23:37:50 +08:00
Surya Prakash Singh
c7f5a388d7 Heat configuration param change for heat-api section
Making variable name "works" to "workers" for correct configuration
as followed in other services

Closes-Bug: #1655081

Change-Id: I333b7a7a98770e640db49e8103900957c629bad5
2017-01-10 04:27:04 +00:00
caoyuan
57ee8b3751 Move heat precheck into its own role
Change-Id: I7de1322ae1efe3797ed5be8ebe2f7359142b077f
Partially-implements: blueprint condition-pre-check
2016-12-28 14:26:12 +08:00
Eduardo Gonzalez
775d8019b6 Add custom policies in service.json
Include custom policy.json files in service-api.json.j2 files

Change-Id: Ic55bfc6f61131aa72c3497ce8b2282056bcc7f92
Partially-Implements: blueprint custom-policies
2016-12-02 16:22:17 +00:00
Duong Ha-Quang
b5d1e4b457 Fix placement of policy.json
Currently, policy.json is put in
"{{ node_config_directory }}/{{ service_name }}"
in target nodes.

Relocation policy.json to "{{ node_config_directory }}/{{ item }}"
with item is corresponding service compoment config directory.

Currently, the policy.json is copied to all services, but it
should be reviewed and left only in neccesary service
(at many cases, only API service needs that).

Redundant files will be removed in follow up patchset.

Change-Id: I0e997dccf4ec438c9c0436db71ec2fd06650f50d
Closes-Bug: #1639686
2016-11-29 16:00:09 +07:00
Jenkins
dbc881456b Merge "Custom policy files" 2016-11-04 13:42:55 +00:00
Jeffrey Zhang
fa45801946 Move precheck into its own role
* Merge prechecks.yml and site.yml playbook
* Create empty precheck.yml into all roles.

Change-Id: I8a138558a26c0a2a66c5fd48ed37be657c99c1dd
Implements: blueprint condition-pre-check
2016-11-03 14:48:58 +08:00
Eduardo Gonzalez
ef1fd6b8c0 Custom policy files
Allow operators to use their custom policy files.
Avoid maintain policy files in kolla repos, only copying
the files when an operator add their custom config.

Implements: blueprint custom-policies
Change-Id: Icf3c961b87cbc7a1f1dd2ffbfffcf271d151d862
2016-10-28 10:47:05 +01:00
Jenkins
9b7ded1a1c Merge "Use option auth_type in group trustee in heat configuration" 2016-10-20 16:10:13 +00:00
zhubingbing
b361fe8ea2
Fix heat upgrade permission issue
Change-Id: I666368dcb2dd900234b373bfd433ab918233c601
Partial-Bug: #1631503
2016-10-15 20:00:14 +08:00
Jenkins
45b0f2cf63 Merge "Remove do_reconfigure.yml file for all roles" 2016-10-13 16:20:30 +00:00
Christian Berendt
1b519cc300 Use option auth_type in group trustee in heat configuration
This will solve the following issue:

WARNING oslo_config.cfg [-] Option "auth_plugin" from group "trustee"
is deprecated. Use option "auth_type" from group "trustee".

Change-Id: I7343a4a28555495d22a7960bf4d585152505a79c
Closes-bug: #1632064
2016-10-10 21:02:34 +02:00
Martin Matyáš
57ba2cd22f Fix wrong heat trustee configuration
"project_domain_id" and "project_name"
cannot be specified [trustee] section or keystone will throw a
"cannot be scoped to multiple targets" error when we attempt to get
a token scoped to a trust.

Change-Id: I167c0e31835d05b8069fd931ef76fb337dd99207
Closes-Bug: #1628353
2016-09-27 21:04:32 -07:00
Jeffrey Zhang
fa856556d5 Remove do_reconfigure.yml file for all roles
do_reconfigure.yml is introduced to use serial directive. But we use
it in wrong. Now serial has moved to playbook file. So it is time to
remove the do_reconfigure.yml file

Closes-Bug: #1628152
Change-Id: I8d42d27e6bc302a0e575b0353956eaef9b2ca9fd
2016-09-27 15:04:00 +00:00
Eduardo Gonzalez
36f400b80e Fix heat role creation
Change-Id: Ic2a14659f90e5b6060eb695e1f3592db3ae5b907
Closes-Bug: #1626863
2016-09-23 15:23:56 +02:00
Jenkins
9d7ba661f3 Merge "Create the heat_stack_user/owner role in the heat role" 2016-09-22 09:28:50 +00:00
caoyuan
a071bce07b Add "---" into some files of yaml
TrivialFix

Change-Id: Id2cd736f136068514f26977b434b15a8b1ffc8be
2016-09-21 11:52:20 +00:00
Christian Berendt
bcff0f8a9a Create the heat_stack_user/owner role in the heat role
Change-Id: I78ce0071474fc693aa2a05397b2a9b5974266cd9
Partial-bug: #1609814
2016-09-19 10:17:14 +02:00
Mick Thompson
4c1482b999 Added serial option to site.yml.
Useful for upgrade etc., which is preferablly done serially.

Example usage: tools/kolla-ansible deploy OR tools/kolla-ansible upgrade

Closes-Bug: #1576708

DocImpact

Change-Id: I34b2e16f8ce53e472a4682a4738c4ac0f5abf00c
2016-09-13 09:26:51 +00:00
Serguei Bezverkhi
134089d6cd Adding required check for Orchestration Kubernetes
Thgis PS add missing check for Kubernetes orchestration engine,
without these changes, running kolla-ansible genconfig fails
for Kubernetes environment.

TrivialFix

Change-Id: I25eeb7ae3ddba7c924f6d48aa24afdbe74227170
2016-09-12 15:32:42 -04:00