summaryrefslogtreecommitdiff
path: root/gitlab/v4
diff options
context:
space:
mode:
authorNejc Habjan <nejc.habjan@siemens.com>2022-07-23 02:21:48 +0200
committerJohn Villalovos <john@sodarock.com>2022-07-23 07:50:52 -0700
commitc6dd57c56e92abb6184badf4708f5f5e65c6d582 (patch)
treeba4961acf5d1af0e1017d5fc5285eebaa18c603e /gitlab/v4
parent9c5b8d54745a58b9fe72ba535b7868d1510379c0 (diff)
downloadgitlab-c6dd57c56e92abb6184badf4708f5f5e65c6d582.tar.gz
fix(runners): fix listing for /runners/all
Diffstat (limited to 'gitlab/v4')
-rw-r--r--gitlab/v4/objects/runners.py16
1 files changed, 15 insertions, 1 deletions
diff --git a/gitlab/v4/objects/runners.py b/gitlab/v4/objects/runners.py
index 4f9d7ce..df75167 100644
--- a/gitlab/v4/objects/runners.py
+++ b/gitlab/v4/objects/runners.py
@@ -19,6 +19,8 @@ __all__ = [
"RunnerJobManager",
"Runner",
"RunnerManager",
+ "RunnerAll",
+ "RunnerAllManager",
"GroupRunner",
"GroupRunnerManager",
"ProjectRunner",
@@ -39,6 +41,7 @@ class RunnerJobManager(ListMixin, RESTManager):
class Runner(SaveMixin, ObjectDeleteMixin, RESTObject):
jobs: RunnerJobManager
+ _repr_attr = "description"
class RunnerManager(CRUDMixin, RESTManager):
@@ -68,7 +71,7 @@ class RunnerManager(CRUDMixin, RESTManager):
"maximum_timeout",
),
)
- _list_filters = ("scope", "tag_list")
+ _list_filters = ("scope", "type", "status", "paused", "tag_list")
_types = {"tag_list": types.CommaSeparatedListAttribute}
@cli.register_custom_action("RunnerManager", (), ("scope",))
@@ -121,6 +124,17 @@ class RunnerManager(CRUDMixin, RESTManager):
return cast(Runner, super().get(id=id, lazy=lazy, **kwargs))
+class RunnerAll(RESTObject):
+ _repr_attr = "description"
+
+
+class RunnerAllManager(ListMixin, RESTManager):
+ _path = "/runners/all"
+ _obj_cls = RunnerAll
+ _list_filters = ("scope", "type", "status", "paused", "tag_list")
+ _types = {"tag_list": types.CommaSeparatedListAttribute}
+
+
class GroupRunner(RESTObject):
pass