Commit Graph

44 Commits

Author SHA1 Message Date
Alex Kavanagh 9c12812735 Switch the charm to support py3
Some major changes:
* the charm has been rebased (from a Python perspective) to be rooted in
  the charm directory.  This is a single root.
* Imports have been changed so that the don't add lots of imports to the
  namespace of the module doing the import.
* The code that used to run at module import time has been made lazy
  such that it only has to run if the relevant functions are called.
  This includes restart_on_change parameters, the harden function and
  the parameters to the guard_map.  Appropriate changes will be
  submitted to charm-helpers.
* Several tests had to be re-written as (incorrect) mocking meant that
  text fixtures didn't actually match what the code was doing.  Thus,
  the tests were meaningless.
* This has had a net positive impact on the unit tests wrt to importing
  modules and mocking.

Change-Id: Id07d9d1caaa9b29453a63c2e49ba831071e9457f
2018-10-18 15:43:03 +01:00
David Ames 54a7603437 Series Upgrade
Implement the series-upgrade feature allowing to move between Ubuntu
series.

Change-Id: I16393fe61f589ae796c91da9177bfacd774279d0
2018-09-19 07:56:06 +00:00
Frode Nordahl 1ee5ce6b55 Sync charm helpers and enable Rocky func test
Change-Id: Id2784943aa3cd5fbaec451dde735de9574013dc1
2018-08-29 09:02:23 -05:00
Corey Bryant b99070edf6 Sync charm-helpers for Rocky series support
Change-Id: I8e625fb8871a9b6afcedf4633df780bd18233aeb
2018-06-21 18:59:34 +00:00
David Ames f03ccf02b7 Enable Bionic as a gate test
Change bionic test from dev to gate for 18.05.

Change-Id: I5a82ac79b29181fabec41570cd5aa003d2bfb8ea
2018-05-11 16:12:20 -07:00
David Ames 794b8ed0bb Charm-helpers sync to fix CA cert comparison
The comparison of bytes vs string of the CA certificate produces a
false negative. This leads to rewriting certificates and affecting
connectivity to services.

Read in the certificate as bytes as well for a bytes vs bytes
comparison.

Closes-Bug: #1762431

Change-Id: Ie2348a83671b9636bd94227e903b1a50bff7aecc
2018-04-11 14:26:49 -07:00
Billy Olsen d43e264d02 Sync charm-helpers and use VolumeAPIContext
Sync in the charm-helpers to use the new VolumeAPIContext object
in order to determine the volume catalog info to use in the
configuration file.

This is simply an alternative implementation for commit 16ae06bf
which separates the concerns for volume endpoint context and
internal endpoint context.

Change-Id: I187bc8ef5644a59dc5a0b5f7ad66774812a78b78
Related-Bug: #1733566
2018-02-08 19:01:44 -07:00
Ryan Beisner 33881c371b Sync charm-helpers
Notable issues resolved:

openstack_upgrade_available() broken for swift
https://bugs.launchpad.net/charm-swift-proxy/+bug/1743847

haproxy context doesn't consider bindings
https://bugs.launchpad.net/charm-helpers/+bug/1735421

regression in haproxy check
https://bugs.launchpad.net/charm-helpers/+bug/1743287

Change-Id: Ifb1d9e71924db6ab8a3d9ee34fcd1b40f910d68a
2018-01-19 16:18:19 +02:00
Liam Young f427dc5a48 Resync charmhelpers for py3 fixes.
Change-Id: I28457389a65a835204729c5070b420715664aa26
2017-11-13 16:13:50 +00:00
David Ames 1fa5f7a673 Dual Stack VIPs
Enable dual stack IPv4 and IPv6 VIPs on the same interface.
HAProxy always listens on both IPv4 and IPv6 allowing connectivity
on either protocol.

charm-helpers sync for HAProxy template changes.

Change-Id: Ide561155adbe56a4cbc865b683532e00c9c33441
2017-08-14 14:55:18 -07:00
Corey Bryant 1e2647a9b5 Enable minimal cells v2 support
A minimal cells v2 setup is required in Ocata, which includes the
following databases:
 1. An API database (named nova_api)
 2. A special cell0 database (named cell0)
 3. A "cell1" database (named nova - we're using the nova db as cell1)

The order of nova-manage commands is also updated in this commit.
The 'nova-manage api_db sync' must occur first because 'nova-manage
cell_v2' commands use the API database. 'nova-manage db sync' must
then be run after the 'nova-manage cell_v2' commands.

Finally, 'nova-manage cell_v2 discover_hosts' must be run whenever a
new compute node is introduced to add the host to cell1.

This commit includes a sync of charm-helpers to pick up AMQPContext
updates for transport_url.

Change-Id: Ia6f36ca8a360dc8490e9f41b62d499fa4d73d0b9
2017-02-16 18:23:21 +00:00
David Ames c59dd636e8 Charm-helper sync to pull in dns resolve fix
Change d5d2e5064e introduced this fix
However the charm-helpers branch was not merged. This is a
reintroduction of the same code with a charm-helpers sync after the
charm-helpers branch was merged.

Change-Id: I68f53d5d4ed726c14d8cc83c650763fa77a4324d
2017-01-10 13:35:06 -08:00
Ryan Beisner 24df5f451d Update Amulet defs, series metadata and c-h sync
- Sync charm helpers if applicable.

- Fix test executable hashbags for virtualenv prep.

- Add Yakkety-Newton Amulet test definitions.

- Prep Xenial-Ocata Amulet test definitions (not yet enabled).

- Prep Zesty-Ocata Amulet test definitions (not yet enabled).

- Add Zesty charm series metadata.

- Remove Precise charm series metadata if present.

- Remove Precise Amulet test definitions if present.

Change-Id: I42776be9284b0eee2fd58b62b0269a5a3c556453
2016-11-28 14:55:42 -06:00
James Page 58bf5b0628 Add support for application version
Juju 2.0 provides support for display of the version of
an application deployed by a charm in juju status.

Insert the os_application_version_set function into the
existing assess_status function - this gets called after
all hook executions, and periodically after that, so any
changes in package versions due to normal system updates
will also be reflected in the status output.

This review also includes a resync of charm-helpers to
pickup hookenv and contrib.openstack support for this
feature.

Change-Id: I8c1d6b9b6d42bcc357d764ec1bd04a36e9982f57
2016-09-20 12:35:19 +01:00
James Page a05c9c6beb Resync charmhelpers for licensing change
The charm-helpers project have re-licensed to Apache 2.0
inline with the agreed licensing approach to intefaces,
layers and charms generally.

Resync helpers to bring charmhelpers inline with charm
codebase.

Change-Id: I8746721aea508fa01d2b616d580b38f84197759b
2016-07-06 16:39:15 +01:00
Corey Bryant d3f311e97a Sync charm-helpers for openstack-origin-git defaults.
Change-Id: I04c88fe9b84a00fc36134a5c704c9a4f34fee5f6
2016-06-23 09:10:57 -04:00
Liam Young bb9ef8b039 Add pause/resume actions and sync charm-helpers
Adds pause and resume unit to the charm such that the
charm stays paused during maintenance operations.

Change-Id: Ia422aa4077fbdd8cdb0353306c14f5633e2affb8
Partial-Bug: 1558642
2016-03-23 15:41:30 +00:00
Corey Bryant c4020b6d0a [corey.bryant,r=trivial] Sync charm-helpers. 2016-01-04 16:29:34 -05:00
Edward Hope-Morley d7e169d631 [hopem,r=]
Sync charmhelpers to get fix for bug 1499643
2015-09-25 15:35:19 +01:00
Liam Young 08b92a7317 [gnuoy,trivial] Charmhelper sync (+1'd by mojo) 2015-09-03 10:39:34 +01:00
Corey Bryant 334c66c2b7 [corey.bryant,r=trivial] Sync charm-helpers to pick up Liberty support. 2015-08-18 13:34:35 -04:00
Liam Young 97171a3486 [gnuoy,trivial] Pre-release charmhelper sync to pickup leadership election peer migration fix 2015-08-03 14:59:29 +01:00
Liam Young fb46491d74 [gnuoy,trivial] Pre-release charmhelper sync to pickup cli module 2015-07-31 14:10:41 +01:00
Liam Young 8c5f43b1ce [gnuoy,trivial] Pre-release charmhelper sync 2015-07-29 11:46:43 +01:00
Corey Bryant 2ebd710f02 Sync charm-helpers. 2015-07-16 20:18:38 +00:00
Liam Young d4b768f673 Resync le charm helpers 2015-06-04 09:45:01 +01:00
Liam Young d418994ea6 Merged trunk in + LE charmhelper sync 2015-05-11 08:38:35 +01:00
James Page 03b2ce7a9c [jamespage] Trivial resync of charm-helpers to pickup Nuage VSP landing. 2015-04-13 09:51:41 +01:00
Edward Hope-Morley b74dfcaf68 synced charm-helpers 2015-03-26 10:36:30 -07:00
Edward Hope-Morley c850324ed1 [hopem,r=] fix ssl cert inject 2015-03-18 13:31:30 +01:00
Liam Young e6463bb22d Charmhelper leader sync 2015-03-09 16:36:24 +00:00
Liam Young 696d32ae02 Charmsync Leadership election 2015-03-09 12:00:56 +00:00
Liam Young c63649ac21 [gnuoy,trivial] Pre-release charmhelper sync 2015-01-26 09:44:11 +00:00
Corey Bryant 41a28574ec Sync charm-helpers. 2014-12-11 13:40:42 +00:00
Corey Bryant 430f26f7f6 Sync charm-helpers. 2014-12-10 20:28:55 +00:00
Edward Hope-Morley 1ab401f941 synced charm-helpers 2014-09-26 13:41:21 +01:00
Hui Xiang 0c34eae15d Sync charm-helpers, fix ipv6 format address. 2014-09-17 16:37:24 +08:00
Liam Young 77c29732f2 Sync charm helpers 2014-08-26 14:28:26 +01:00
Corey Bryant e2e7e4798d Sync with charm-helpers 2014-07-11 02:43:50 +00:00
Christopher Glass e065be6e4f Updating charm-helpers from lp:charm-helpers revision 153 2014-05-19 13:38:09 +02:00
James Page 400604db75 [ivoks] Re-order port-pipeline to ensure end-to-end SSL 2014-02-19 11:02:03 +00:00
Adam Gandelman 74fcca8d0f Update and sync helpers. 2013-11-05 19:48:26 -08:00
James Page 801ac9b82f resync with helpers 2013-10-22 16:01:40 -07:00
Adam Gandelman f7b057ca60 Check in start of py redux. 2013-08-01 20:42:16 -07:00