Commit Graph

25 Commits

Author SHA1 Message Date
Hamza Alqtaishat 990287677b Adding the senlin resource
This handle the senlin cluster disable/clean
for disable it will detach the polices from the cluster
and resize the cluster to zero (empty cluster)

for clean it will deatach the policies from cluster
clean the policies, receivers then clean the clusters then clean
the profiles

Change-Id: I09421d55c66d91a747bc786fdd250730c79dfd34
2019-10-24 20:31:38 +00:00
Adam Harwell 4bda141c47 Enable some additional functional testing
alt_demo user, non-ascii resource names

Change-Id: I4872d194963c790549c4bd6f03aceec1cb2e25a4
2019-10-22 22:25:18 +00:00
Hamza Alqtaishat 39a159f8c7 Adding the disable feature
This feature allow the disable of most of the project resources
in some cases the admin want to disable the project and wait
for period of time before deleting the resources just in case
some resources are still usable or need to be moved to another
project

for nova the disable will stop the servers
for neutron it will change the admin_state_up to false which
will change the status of resource to down
for glance it will deactivate the images
for swift it will remove the read/write acls to container
for octaivia chenge the admin_state_up to false making the
status of loadbalancer down
for cinder it will change the volume to readonly

for the resources that dont have a way of disabling the
resource it will just log a warning

Change-Id: Ic2af6ad1ffb1e749a3d1ba687950264b5098bcdb
2019-10-14 21:33:38 +00:00
Adam Harwell 7044205c34 Add Octavia support
Includes functional testing.

Change-Id: I8d2152d2f354cfb882f534d23f150d6962195b0f
2019-10-01 20:09:37 -07:00
Adam Harwell 0421d12397 Modernize testing and clients
Update to use a new-style zuul role for devstack testing.
Remove references to Shade/os_client_config and use OpenstackSDK.

Change-Id: Ieecc4043b613e333948c32e7e93ad1d383d1f3ec
2019-10-01 20:09:32 -07:00
Jordan Pittier 98a0fb2405 Update default cirros version
Following I419348f1784600e3989c8e86a99c04b24f3610c4

Change-Id: I0661144bb6f6d26b3026b011a7fbb01f1998279a
2019-03-12 18:38:39 +01:00
Graham Hayes 11e2fdd2fb
Add functional testing for Designate
Change-Id: If9fe00c437e6ca1341c72c1081eee35ad2ee46d2
Signed-off-by: Graham Hayes <gr@ham.ie>
2018-10-19 16:31:39 +01:00
Tobias Urdin ebb02fde0a Fix functional testing
Fixes for the functional testing using
devstack.

Change-Id: I3a510b6405464fe966cb7cb5ea0a1321b9e7e34f
2018-09-08 22:51:08 +02:00
Victor Stinner 90642dd2ec Fix functional tests
* Use an ASCII name for the VM name to workaround a Nova bug.
* Pass --os-domain-id parameter to ospurge to purge the
  invisible_to_admin project

Related-Bug: #1730756
Change-Id: Ie1507a3564d1d8919148228fa647be63e725c7bc
2017-11-08 23:09:50 +01:00
Jordan Pittier ff7ec78f43 Disable a failing functional test
It doesn't work. Let's unblock the gate.

Change-Id: I7be7fed76f2bd8842f5a9fb088cf52897bb73d8b
2017-07-11 21:29:25 +02:00
Jordan Pittier 7bf67dd293 Gate functional job: assert volumes are correctly cleaned up
After OSPurge has ran on one project, this patch asserts that volumes
and volume backups in other projects have not been deleted.

Also, we must separate the case when cinder-backup is running and when
it is not. We know (for now) that c-bak is enabled in Gate runs.

Change-Id: I0064e43c7b8476943370aa365b6c0d3160d157b0
2017-03-13 15:55:54 +01:00
Jordan Pittier f83b138fa8 Update functional job
Change-Id: Ie29ceecb56aaae6e7bf2b9d91634b2b17a9ae9c3
2017-02-27 22:04:23 +01:00
Jordan Pittier f86c9b8360 Prepare functional tests in Gate run
We need to have, in addition to unit tests, some functional tests
running.

Change-Id: I26ed40a5035c3129bb93319f67d8df940677afa2
2017-01-24 14:28:21 +01:00
Jordan Pittier 3a612efd53 OSPurge version 2
This commit is a whole new version of OSPurge. Currently OSPurge suffers
from the following limitations:
* It's slow (monothread)
* It's not guaranteed to complete. If a resource fails to be deleted then
OSPurge can choke on deleting other resources that depends on the first one.
* Not properly unit tested.
* Not modular (one huge file to deal with all services)

This new version is:
* Faster (multithreaded, thanks to a ThreadPoolExecutor)
* Safe (we check and wait for some prerequisites before attempting a
delete)
* 100% unit tested.
* Modular (one file per service)

Note that it's Python3.5 compatible. It also uses OpenStack Shade
and OpenStack client-config libraries so that OSPurge focuses on the
cleaning logic only.

Overall I believe this is a better version of OSPurge and more future
proof. NOte that we tagged and released OSPurge 1.3 recently in case
the new version was not satisfactory to everybody.

Change-Id: I5eb92a0556df210ea3cb4e471b8db3b5bf7ed5ee
2016-12-15 10:49:25 +01:00
Christian Berendt 0e81a56580 [ospopulate] use '|| true' instead of 'if ! ...'
Change-Id: I74f66c44d946ca3e83b5b222753d8d10b0b0b99c
2015-11-24 08:13:27 +00:00
Christian Berendt b4f0decc65 [ospopulate] create neutron firewall and loadbalancer resources
Change-Id: I7580b5a2823a95c05a1d9659d91024c8a19e79d7
2015-11-24 08:13:13 +00:00
Jenkins 2a12a76965 Merge "[ospopulate] add .gitignore file to ignore files created by ospopulate script" 2015-11-23 12:23:01 +00:00
Christian Berendt e42bc15260 [ospopulate] add .gitignore file to ignore files created by ospopulate script
Change-Id: I37ce321522cccea0d6009e07806ea7eb0c92c0c3
2015-11-19 21:36:37 +00:00
Christian Berendt f0799ced9f [ospopulate] add prefix "ospurge_" to all created resources
Adding the prefix "ospurge_" helps to identify resources created for
ospurge tests.

Change-Id: I83c7f13471baf7e458d7972d2e813d04776253fc
2015-11-19 21:35:32 +00:00
Christian Berendt 5aed7aec2a [ospopulate] create a ceilometer alarm
Change-Id: I871b9de5e41f3882545e49cd3374af7f1beca53f
2015-11-19 21:35:21 +00:00
Christian Berendt 6fc4c7a8fd [ospopulate] use latest available Cirros image version 0.3.4
Change-Id: I2453dbb1d426d202346e10ade67ef65537b1ef48
2015-11-19 21:34:52 +00:00
Christian Berendt 3cabda8931 [ospopulate] check if variable OS_TENANT_NAME is set and non-empty
Change-Id: I6526235547e02ec4ac72cea6678d86e04c8a21ef
2015-11-19 21:34:44 +00:00
Christian Berendt 0d906d8649 Fix syntax issues in bash scripts and add bashate check
* [E] E003: Indent not multiple of 4

Change-Id: I7cd5c8b5348de065d84d03a316dc120f121841f3
2015-11-19 22:34:15 +01:00
Jordan Pittier 92452098ef General improvements of tools/ospopulate.bash
Work items:
  * Create a dummy Heat stack
  * Introduce shell variables for external network name, flavor name
    and image name that can be overriden by the ENV
  * Check that those variables correspond to resources that actually
    exist on the Cloud
  * Fix a bug in exit_if_empty use: if $1 was actually empty then $2
    would be mistakenly used as $1 (an empty string is not considered
    as an argument in bash)

Change-Id: I727dc90029aa26820f6e9e29ca112b7ef2a69800
2015-10-23 22:41:20 +02:00
Florent Flament 3d42f36946 Add ospopulate.bash tool - create resources to test ospurge
ospopulate.bash creates a bunch of resources in the project set by the
OS_TENANT_NAME environment variable. Credentials have to be set in the
environment as usual. The goal of ospopulate.bash is to ease testing
of ospurge.

Change-Id: I14da32cbc690f3fd21706dd808ac25563d48a689
2015-01-30 14:10:28 +01:00