cli.add_forge_now: Open `register-lister` with sensible defaults
This will ease scheduling of new add-forge-now requests, on: - staging: this will list a subset of disabled origins once - production: this will register recurring tasks (full, incremental if any) to list that new forge This also unifies the previous subcommand schedule-first-visits with the --preset flag. So, the following would be enough to list appropriately in staging/production: ``` swh scheduler add-forge-now \ ( --preset [production|staging] \ # to enable a pre-defined set of rules ) register-lister \ gitea \ url=https://git.afpy.org/api/v1/ ``` Related to https://gitlab.softwareheritage.org/infra/sysadm-environment/-/issues/4674
Showing
- requirements-test.txt 0 additions, 1 deletionrequirements-test.txt
- swh/scheduler/cli/__init__.py 10 additions, 1 deletionswh/scheduler/cli/__init__.py
- swh/scheduler/cli/add_forge_now.py 84 additions, 12 deletionsswh/scheduler/cli/add_forge_now.py
- swh/scheduler/cli/origin.py 1 addition, 1 deletionswh/scheduler/cli/origin.py
- swh/scheduler/cli/task.py 19 additions, 148 deletionsswh/scheduler/cli/task.py
- swh/scheduler/cli/test_cli_utils.py 17 additions, 0 deletionsswh/scheduler/cli/test_cli_utils.py
- swh/scheduler/cli/utils.py 159 additions, 2 deletionsswh/scheduler/cli/utils.py
- swh/scheduler/tests/test_cli_add_forge_now.py 86 additions, 10 deletionsswh/scheduler/tests/test_cli_add_forge_now.py
Loading
Please register or sign in to comment