summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDmitry Poray <dmip@interprogma.ru>2016-11-07 20:11:54 +0300
committerDmitry Poray <dmip@interprogma.ru>2016-11-15 17:19:33 +0300
commitff8194e0ec16092419862011d7cc048baa149c42 (patch)
treeeaaf61f02c9c2d59719a3a941463a9ed2a0565f3 /lib
parentc5e147de1288130147ec0f500bea50353d441cb8 (diff)
downloadgitlab-ce-ff8194e0ec16092419862011d7cc048baa149c42.tar.gz
Add ref parameter for triggerring builds with gitlab webhook from other project.
Diffstat (limited to 'lib')
-rw-r--r--lib/api/triggers.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/api/triggers.rb b/lib/api/triggers.rb
index 9a4f1cd342f..569598fbd2c 100644
--- a/lib/api/triggers.rb
+++ b/lib/api/triggers.rb
@@ -12,7 +12,7 @@ module API
requires :token, type: String, desc: 'The unique token of trigger'
optional :variables, type: Hash, desc: 'The list of variables to be injected into build'
end
- post ":id/trigger/builds" do
+ post ":id/(ref/:ref/)trigger/builds" do
project = Project.find_with_namespace(params[:id]) || Project.find_by(id: params[:id])
trigger = Ci::Trigger.find_by_token(params[:token].to_s)
not_found! unless project && trigger