Commit Graph

532 Commits

Author SHA1 Message Date
Peter Sabaini 913cb57b1f Doc: describe the s3 interface
Change-Id: I9379ca1bdc29eb2ef7cbd16255c457f37e30021f
2024-02-06 18:19:30 +01:00
Peter Sabaini 92caaa710b Initial support for the s3 interface
Implement initial support for the s3 interface here:
https://github.com/canonical/charm-relation-interfaces/tree/main/interfaces/s3/v0

Drive-by: fully qualify rename.sh in allowlist_externals

Change-Id: I8a78c41840c529cf2c35f487739c0397e4374f97
2024-02-02 12:09:04 +01:00
Zuul 8b7522b906 Merge "Allow URLs which contain encoded path separators" 2024-01-24 22:22:35 +00:00
Luciano Lo Giudice 07898679ca Revert default source to 'bobcat'
The Openstack libs don't recognize Ceph releases when specifying
the charm source. Instead, we have to use an Openstack release.
Since it was set to quincy, reset it to bobcat.

Change-Id: I5b82c876184025a790e2b0cab84348c71a8a4a55
2024-01-15 14:48:42 -03:00
peppepetra86 8a844bca97 Allow URLs which contain encoded path separators
This is to resolve the issue with objects containing slash in the name
not correctly synced in multisite environments.

Closes-Bug: #1974138
Change-Id: I71ac000bb4754c9cb987d703f145dc2a5ff032ad
2024-01-09 10:06:24 +01:00
Ionut Balutoiu b24a35713a Improve platform mocking
Patch out charmhelpers.osplatform.get_platform() and
charmhelpers.core.host.lsb_release() globally in the unit tests to
insulate the unit tests from the platform that the unit tests are being
run on.

Also, add mock for `charmhelpers.contrib.openstack.context.is_ipv6_disabled`
in the `HAProxyContextTests.test_ctxt` unit test.

The charmhelpers function `is_ipv6_disabled` calls `sysctl` and this doesn't
exist on Debian container images. This fixes the following unit test failure:
```
FileNotFoundError: [Errno 2] No such file or directory: 'sysctl'
```

Signed-off-by: Ionut Balutoiu <ibalutoiu@cloudbasesolutions.com>
Co-authored-by: Alex Kavanagh <alex.kavanagh@canonical.com>

Change-Id: I60bc9550a83eb342e78d3c1916d98bfaa8035572
2023-10-30 17:52:43 +02:00
Zuul 976fc4ae84 Merge "Add upgrade func testing" 2023-09-29 16:07:45 +00:00
Peter Sabaini be056d6ca6 Add upgrade func testing
Change functional testing to also test upgrades from charmhub version
to the locally built charm. Include a new test for installing a locally built charm from scratch.

Also pin some support charms to specific tracks.

Change-Id: I57937f55526f531cb807a876fd074f5f589b00ed
2023-09-28 21:47:28 +02:00
Luciano Lo Giudice 56c95bac5b Sync charm libraries
Change-Id: I3cc5a774f0d4fec2eb7fb719579df6fce24167ef
2023-09-13 14:10:47 -03:00
Zuul 84356bad04 Merge "Fixes testcase coverage for charm" 2023-09-12 05:48:15 +00:00
Zuul dd8a9d9494 Merge "Ensure get_requests_for_local_unit doesn't fail on incomplete relation" 2023-09-12 05:47:54 +00:00
Peter Sabaini 4d36f6cbc3 Prune CI jobs
Change-Id: I4260d8c4ea6e5a7cedca4231dec42d0700e25638
2023-09-11 17:22:05 +02:00
Utkarsh Bhatt b2c722b9ce Fixes testcase coverage for charm
Change-Id: I6f778f4b34e48c06d7ac4e9ef2f9c6633bf04ba0
2023-09-01 10:21:31 +00:00
Alex Kavanagh 40782db848 Ensure get_requests_for_local_unit doesn't fail on incomplete relation
This is a rebuild/make sync for charms to pickup the fix in charmhelpers to fix
any inadvertant accesses of ['ca'] in the relation data before it is available
from vault in the certificates relation.  Fix in charmhelpers is in [1].

[1] https://github.com/juju/charm-helpers/pull/824
Closes-Bug: #2028683

Change-Id: Ie05a9ff536700282dc0c66816b50efee5da62767
2023-08-21 11:20:37 +01:00
Zuul 4bc15968fe Merge "Fix pool names in RadosGW charm" 2023-08-14 14:33:52 +00:00
Luciano Lo Giudice fd4497f8dc Fix pool names in RadosGW charm
The latest Ceph versions forbid pool names that start with a dot.
Since the RadosGW charm uses pools named so extensively, this
patchset fixes that issue.

In addition, the Ceph libraries are synced as well, since they
were outdated.

Change-Id: I50112480bb3669de08ee85a9bf9a594b379e9ec3
2023-08-09 11:36:16 -03:00
Jadon Naas ac9c22c3df Fix typo in actions.yaml
There was a typo in actions.yaml for the resume action that was breaking
builds. This change fixes that typo. The charm will build.

Closes-Bug: 2030677
Change-Id: I4501c3142620dc6bff87f554a9f26b39ac4c927d
2023-08-08 10:30:15 -04:00
Zuul 7afb253cf6 Merge "Add 2023.2 Bobcat support" 2023-08-07 19:08:05 +00:00
Corey Bryant 37cb69d7f8 Add 2023.2 Bobcat support
* sync charm-helpers to classic charms
* change openstack-origin/source default to quincy
* add mantic to metadata series
* align testing with bobcat
* add new bobcat bundles
* add bobcat bundles to tests.yaml
* add bobcat tests to osci.yaml
* update build-on and run-on bases
* drop kinetic
* add additional unit test https mocks needed since
  charm-helpers commit 6064a34627882d1c8acf74644c48d05db67ee3b4
* update charmcraft_channel to 2.x/stable

Change-Id: I2d9c41c294668c3bb7fcba253adb8bc0c939d150
2023-08-02 14:10:40 -04:00
Jadon Naas 14a195d942 Add docs key and point at Discourse
Add the 'docs' key and point it at a Discourse topic
previously populated with the charm's README contents.

When the new charm revision is released to the Charmhub,
this Discourse-based content will be displayed there. In
the absense of the this new key, the Charmhub's default
behaviour is to display the value of the charm's
'description' key.

Change-Id: Id759ee81cea83fe9b18671ce5bc19a31db319a77
2023-07-18 14:14:52 -04:00
utkarshbhatthere 7feab3a45b
Adds focal to charmcraft
Change-Id: Id74fa86d80e6e7bf16ee048bb6277f082705e8d7
Signed-off-by: utkarshbhatthere <utkarsh.bhatt@canonical.com>
2023-06-27 13:02:56 +05:30
Samuel Walladge 541ceec401 Enable rgw trust forwarded https when https proxy
This option is required for server-side encryption to be allowed
if radosgw is behind a reverse proxy,
such as here when certificates are configured and apache2 is running.

ref. https://docs.ceph.com/en/latest/radosgw/encryption/

It is safe to always enable when https is configured in the charm,
because it will be securely behind the reverse proxy in the unit.
This option must not be enabled when https is not configured in the charm,
because this would allow clients to spoof headers.

Closes-Bug: #2021560
Change-Id: I940f9b2f424a3d98936b5f185bf8f87b71091317
2023-05-31 14:16:47 +09:30
Zuul 4484b0f0ed Merge "Removes stderr pipe from _check_output" 2023-05-26 17:36:22 +00:00
Felipe Reyes 8e9d25f72e Charm-helpers sync
charm-helpers sync to pick up Antelope UCA support

Change-Id: Ie649be98ecd338b6441a59a0ad32aa696fc8ca99
2023-04-06 15:57:18 -04:00
Chris MacNaughton a1267f4919 Add support for interim Ubuntu releases
- update bundles to include UCA pocket tests
- update test configuration
- update metadata to include kinetic and lunar
- update snapcraft to allow run-on for kinetic and lunar

Change-Id: I05ce01c13efdd453c06e3c8d615d64bad6e27727
2023-03-20 13:39:08 -04:00
Felipe Reyes 1fff8f052b Add kinetic support
Add 22.10 run-on base and add kinetic to metadata.yaml.

Change-Id: Ie057238ac1d3640047480cd243a9b4fb9e0eae30
2023-02-21 14:55:07 -03:00
Utkarsh Bhatt b76b1df0dd
Removes stderr pipe from _check_output
Change-Id: Ia6e838d607fecb9b391ebc450d611af1865b2eab
2023-02-01 17:08:03 +05:30
Liam Young fc3462b6a7 Fix charm for tox4 compatibility
Related-Bug: 2002788
Change-Id: I49c3864dbe7ad476e67c6ade54d352e0520682b9
2023-01-17 08:55:53 +00:00
Chris MacNaughton bb16e670dc Partial revert[1] to re-enable Focal support
1: 51f59879d3
Change-Id: I565e36b94d249d2cf0beccf1480189a19da008d9
2022-10-31 14:20:36 +01:00
utkarshbhatthere db79f28906 Fixes openssl dependency issue for tests
Change-Id: I2cfaf1de8d2096522cb435751be874df0d985578
2022-09-28 07:54:41 +00:00
utkarshbhatthere 367a2aedcb Adds primary/secondary multisite relation
A new relation with primary/secondary nomenclature is added and the
old master/slave relation is marked as *Deprecated*. In future,
master/slave relation would be completely removed.

Change-Id: I9cda48b74a20aaa9a41baedc79332bfaf13951d3
func-test-pr: https://github.com/openstack-charmers/zaza-openstack-tests/pull/926
2022-09-23 18:17:42 +00:00
Zuul c1c9531a7f Merge "Adds support for scaling down multisite rgw system" 2022-09-12 18:48:30 +00:00
utkarshbhatthere cb70cf4c5f Adds support for scaling down multisite rgw system
Adds implementation for relation-departed hooks to cleanly remove
participant sites from the multisite system. The replication
between zones is stopped and both zones split up to continue as
separate master zones.

Change-Id: I420f7933db55f3004f752949b5c09b1b79774f64
func-test-pr: https://github.com/openstack-charmers/zaza-openstack-tests/pull/863
2022-09-08 08:09:21 +00:00
Zuul 349f90828e Merge "Add Kinetic and Zed support" 2022-08-30 03:56:38 +00:00
Corey Bryant 51f59879d3 Add Kinetic and Zed support
* sync charm-helpers to classic charms
* change openstack-origin/source default to zed
* align testing with zed
* add new zed bundles
* add zed bundles to tests.yaml
* add zed tests to osci.yaml and .zuul.yaml
* update build-on and run-on bases
* add bindep.txt for py310
* sync tox.ini and requirements.txt for ruamel
* use charmcraft_channel 2.0/stable
* drop reactive plugin overrides
* move interface/layer env vars to charmcraft.yaml

Change-Id: Ieb1ef7b7ab76775f5769621a6a7cbcfb18c40b7f
2022-08-26 18:40:29 +00:00
utkarshbhatthere e97e3607e2
Adds existence verification for config values
Multisite config values (realm, zonegroup, zone) are written
to ceph.conf as the defaults without verifying their existence, this
causes failure for commands which use the default values.

Closes-Bug: #1987127
Change-Id: I0ab4df34f0000339227e5d5b80352355ea7bd36e
2022-08-24 18:35:44 +05:30
utkarshbhatthere 44fee84d4d
Adds support for migration to multi-site system.
1.) Currently multi-site can only be configured when system is being
deployed from scratch, migration works by renaming the existing
Zone/Zonegroups (Z/ZG) to Juju config values on primary site before
secondary site pulls the realm data and then rename and configure
secondary Zone accordingly.

During migration:
2.) If multiple Z/ZG not matching the config values are present at
primary site, the leader unit will block and prompt use of
'force-enable-multisite' which renames and configures selected Z/ZG
according to multisite config values.

3.) If the site being added as a secondary already contain Buckets,
the unit will block and prompt the operator to purge all such Buckets
before proceeding.

Closes-Bug: #1959837
Change-Id: I01a4c1c4551c797f0a32951dfbde8a1a4126c2d6
func-test-pr: https://github.com/openstack-charmers/zaza-openstack-tests/pull/840
2022-08-07 13:32:37 +05:30
Luciano Lo Giudice 5c4cab3f82 Add the 'zonegroup' and 'realm' keys to ceph.conf file
This patchset adds these 2 additional keys to the ceph.conf file,
which are used in multisite configurations when present.

Change-Id: I51ca46bbb3479cb73ec4d9966208ed794f0ed774
Closes-Bug: #1975857
2022-05-31 18:08:13 -03:00
Ethan Myers 2bda1f68a6 Add a config option for relaxed s3 bucket names.
Closes-Bug: #1926498
Change-Id: I4b329f3327a0e91ccd9f65841cc5d62736918a85
2022-05-19 15:02:03 +00:00
Chris MacNaughton b069b3aa4c Multisite replication should use public, rather than internal, networks
Closes-Bug: #1960520
Change-Id: Ie2954a9a59acbc384c18c901e2d324ee003d7108
2022-04-18 07:13:35 -07:00
Chris MacNaughton 1f4dbd3a5d Updates for jammy enablement
- charmcraft: build-on 20.04 -> run-on 20.04/22.04 [*archs]
- Refresh tox targets
- Drop impish bundles and OSCI testing
- Add jammy metadata
- Default source is yoga
- Charmhelpers and charms.ceph sync

Change-Id: I39f091db8ef8f18c0a40d4e46d54dfc964c03d70
2022-04-08 10:23:48 +01:00
James Page 7907fa96e9 Resolve issue with mod_proxy decoding
The Ceph RADOS Gateway uses some unusual URI's for multisite
replication; ensure that mod_proxy passes the 'raw' URI down
to the radosgw http endpoint so that client and server side
signatures continue to match.

This seems quite Ceph specific so the template is specialised
into the charm rather than updated in charm-helpers.

Change-Id: Iede49ba8904500076d53388345e154a3ed18e761
Closes-Bug: 1966669
2022-03-30 13:47:53 +01:00
Zuul 25885fdd0e Merge "Ceph Quincy dropped support for the Civetweb http frontend." 2022-03-10 16:06:31 +00:00
Zuul 88d1f4b0a5 Merge "Enable HAProxy HTTP Health Checks" 2022-03-04 16:15:19 +00:00
Chris MacNaughton b00783c14c Ceph Quincy dropped support for the Civetweb http frontend.
Change-Id: I2428cd34110fbc8f7775eb79fe70c34a4eafe3eb
2022-02-24 11:41:11 +01:00
Cornellius Metto 31a4584169 Enable HAProxy HTTP Health Checks
Ceph radosgw supports [0] the swift health check endpoint
"/swift/healthcheck". This change adds the haproxy
configuration [1] necessary to take the response of "GET
/swift/healthcheck" into account when determining the health
of a radosgw service.

For testing, I verified that:
- HAProxy starts and responds to requests normally with this
  configuration.
- Servers with status != 2xx or 3xx are removed from the
  backend.
- Servers that take too long to respond are also removed
  from the backend. The default timeout value is 2s.

[0] https://tracker.ceph.com/issues/11682
[1] https://www.haproxy.com/documentation/hapee/2-0r1/onepage/#4.2-option%20httpchk

Closes-Bug: 1946280
Change-Id: I82634255ca3423fec3fc15c1e714dcb31db5da7a
2022-02-18 12:50:54 +03:00
Zuul 56f80952c4 Merge "Charmhelpers Sync: https health checks for HAProxy" 2022-02-18 09:48:51 +00:00
Alex Kavanagh d81d4bb128 Update to classic charms to build using charmcraft in CI
This update is to ensure that the Zuul Canonical CI builds the charm
before functional tests and ensure that that artifact is used for the
functional tests.  This is to try to ensure that the charm that gets
landed to the charmhub is the same charm that was tested with.

Change-Id: I56e04707036b994c52cc9cfcb19e6c37cd41309e
2022-02-15 15:43:00 +00:00
Chris MacNaughton 043c4fd795 Fix OSCI voting on xena
Change-Id: I2d1eaa2d0d69bfc5d72d8350a7f94f6a76698644
2022-02-10 17:29:59 +01:00
Cornellius Metto 158c42b4a9 Charmhelpers Sync: https health checks for HAProxy
Change-Id: I4848168b5a45c3430dec58f786d4453e40539361
2022-02-07 13:04:35 +03:00