summaryrefslogtreecommitdiff
path: root/gitlab/objects.py
diff options
context:
space:
mode:
authorGauvain Pocentek <gauvain@pocentek.net>2016-08-27 23:10:19 +0200
committerGauvain Pocentek <gauvain@pocentek.net>2016-08-27 23:10:19 +0200
commit8d7faf42b3e928ead8eb6eb58b7abf94364b53e2 (patch)
treee34834aea728a625c1d5ca1cb5c3e20d61b756cf /gitlab/objects.py
parent40db4cdd24cf31fd6a192b229c132fe28e682eb8 (diff)
downloadgitlab-8d7faf42b3e928ead8eb6eb58b7abf94364b53e2.tar.gz
Add support for project deployments
Diffstat (limited to 'gitlab/objects.py')
-rw-r--r--gitlab/objects.py12
1 files changed, 12 insertions, 0 deletions
diff --git a/gitlab/objects.py b/gitlab/objects.py
index bf46f87..5a23dbf 100644
--- a/gitlab/objects.py
+++ b/gitlab/objects.py
@@ -1862,6 +1862,17 @@ class ProjectAccessRequestManager(BaseManager):
obj_cls = ProjectAccessRequest
+class ProjectDeployment(GitlabObject):
+ _url = '/projects/%(project_id)s/deployments'
+ canCreate = False
+ canUpdate = False
+ canDelete = False
+
+
+class ProjectDeploymentManager(BaseManager):
+ obj_cls = ProjectDeployment
+
+
class Project(GitlabObject):
_url = '/projects'
_constructorTypes = {'owner': 'User', 'namespace': 'Group'}
@@ -1890,6 +1901,7 @@ class Project(GitlabObject):
[('project_id', 'id')]),
('commit_statuses', ProjectCommitStatusManager,
[('project_id', 'id')]),
+ ('deployments', ProjectDeploymentManager, [('project_id', 'id')]),
('environments', ProjectEnvironmentManager, [('project_id', 'id')]),
('events', ProjectEventManager, [('project_id', 'id')]),
('files', ProjectFileManager, [('project_id', 'id')]),