blob: 66ea655c9ccd0901aab3032d1650f0fb21d78cd9 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
|
require_relative 'http_client'
class GitalyClient < HttpClient
attr_reader :gitaly_url
def initialize(gitaly_url)
@gitaly_url = gitaly_url
end
def notify_post_receive(repo_path)
url = "#{gitaly_url}/post-receive"
params = { project: sanitize_path(repo_path) }
resp = post(url, params)
resp.code == '200'
end
end
|