This section describes different ad-hoc scripts used by Waldur developers.
Restore CPU/GPU/RAM usages for a month
Sometimes, Waldur can have issues with data correctness. They can be caused by different circumstansies, e.g. problems with data syncronization between Waldur backend and service provider software. In order to resolve these issues, a user can restore usage data with restore_usages.py script.
Generate openmetrics file with usages for several months
Prolong expired projects
If a user needs to prolong an expired project with remote resources, this script should be used. It can:
- automatically detect projects with pending update requests
- approve the requests
- set state OK for terminating resources both in a local Waldur and remote one
Note: the script must be executed in a local Waldur instance
Wipe tenants and all related resources from OpenStack
If a user needs to remove a tenant with all related objects (instances, volumes, backups, etc.) manually, this script should be used. It removes all the tenants with names from
tenant_names list using an OpenStack administrator project. Please, replace
<main-tenant-uuid> (line 13) with the corresponding UUID of the admin tenant in Waldur.