Commit Graph

13 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
Chris MacNaughton 86fa317420 Sync charm-helpers to ensure Rocky support
Change-Id: Ib117de4541e0cdc23aa72859d2d878e6ef7ba651
2018-07-13 15:57:26 +02:00
Corey Bryant b99070edf6 Sync charm-helpers for Rocky series support
Change-Id: I8e625fb8871a9b6afcedf4633df780bd18233aeb
2018-06-21 18:59:34 +00: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
Liam Young f427dc5a48 Resync charmhelpers for py3 fixes.
Change-Id: I28457389a65a835204729c5070b420715664aa26
2017-11-13 16:13:50 +00:00
Ryan Beisner dda468d57f Sync charm-helpers
Change-Id: I9e06f9bed79a82585fef930e1e835ca374619f40
2017-08-24 17:12:03 -05:00
James Page b1da4f2dd4 Update notification config >= mitaka
Use oslo_messaging_notifications for mitaka or later releases
including setting the transport_url to the value provided by
the AMQP context.

This removes use of deprecated configuration options for
ceilometer notifications.

Change-Id: Ia57f29abbbabf1712b2385c2d94ece12f9ce0861
2017-07-31 10:41:26 +01:00
James Page 7186587ac6 Updates for Pike b1
Resync charmhelpers to pickup new versions for Pike.

Add amulet tests for pike, but leave disabled for now.

Change-Id: I2d828fa88b73260b2abf02ff2c6037ffbee654f3
2017-05-24 11:04:13 +01:00
David Ames bb4b8d6540 Enable Ocata Amulet Tests
- Add Zesty as a supported series to metadata.yaml.
- Turn on Xenial-Ocata Amulet test definitions.
- Sync charm helpers to get Juju 2.x amulet compatibility.
- Keeping Zesty-Ocata Amulet test definitions turned off until the
  metadata.yaml changes propagate to the charm store.

Change-Id: I0f824bf80beeb8509b2958d429aaed52f4cf46bb
2017-03-09 14:35:03 -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
David Ames 94966e0e59 Pre-release charm-helpers sync 16.10
Get each charm up to date with lp:charm-helpers for release testing.

Change-Id: Iab6950c48e91266f5471a4180e9e94479d955e34
2016-09-30 09:10:55 -07: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