2018-08-27 23:43:11 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
module Gitlab
|
|
|
|
module GitAccessResult
|
|
|
|
class CustomAction
|
2019-10-23 14:06:07 -04:00
|
|
|
attr_reader :payload, :console_messages
|
2018-08-27 23:43:11 -04:00
|
|
|
|
|
|
|
# Example of payload:
|
|
|
|
#
|
|
|
|
# {
|
|
|
|
# 'action' => 'geo_proxy_to_primary',
|
|
|
|
# 'data' => {
|
2020-04-09 14:09:34 -04:00
|
|
|
# 'api_endpoints' => %w{geo/proxy_git_ssh/info_refs_receive_pack geo/proxy_git_ssh/receive_pack},
|
2018-08-27 23:43:11 -04:00
|
|
|
# 'gl_username' => user.username,
|
2020-10-05 11:08:56 -04:00
|
|
|
# 'primary_repo' => geo_primary_http_url_to_repo(container)
|
2018-08-27 23:43:11 -04:00
|
|
|
# }
|
|
|
|
# }
|
|
|
|
#
|
2019-10-23 14:06:07 -04:00
|
|
|
def initialize(payload, console_messages)
|
2018-08-27 23:43:11 -04:00
|
|
|
@payload = payload
|
2019-10-23 14:06:07 -04:00
|
|
|
@console_messages = console_messages
|
2018-08-27 23:43:11 -04:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|