Welcome to mirror list, hosted at ThFree Co, Russian Federation.

ssh.proto « proto - gitlab.com/gitlab-org/gitaly.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 43367d330a39d0ff6884ad865b63a6666b36e3e3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
syntax = "proto3";

package gitaly;

option go_package = "gitlab.com/gitlab-org/gitaly/proto/go/gitalypb";

import "lint.proto";
import "shared.proto";

service SSHService {
  // To forward 'git upload-pack' to Gitaly for SSH sessions
  rpc SSHUploadPack(stream SSHUploadPackRequest) returns (stream SSHUploadPackResponse) {
    option (op_type) = {
      op: ACCESSOR
    };
  }

  // To forward 'git receive-pack' to Gitaly for SSH sessions
  rpc SSHReceivePack(stream SSHReceivePackRequest) returns (stream SSHReceivePackResponse) {
    option (op_type) = {
      op: MUTATOR
    };
  }

  // To forward 'git upload-archive' to Gitaly for SSH sessions
  rpc SSHUploadArchive(stream SSHUploadArchiveRequest) returns (stream SSHUploadArchiveResponse) {
    option (op_type) = {
      op: MUTATOR
    };
  }
}

message SSHUploadPackRequest {
  // 'repository' must be present in the first message.
  Repository repository = 1 [(target_repository)=true];
  // A chunk of raw data to be copied to 'git upload-pack' standard input
  bytes stdin = 2;
  // Prevent re-use of field id 3 and/or the "git_config_parameters" name
  reserved 3;
  reserved "git_config_parameters";
  // Parameters to use with git -c (key=value pairs)
  repeated string git_config_options = 4;

  // Git protocol version
  string git_protocol = 5;
}

message SSHUploadPackResponse {
  // A chunk of raw data from 'git upload-pack' standard output
  bytes stdout = 1;
  // A chunk of raw data from 'git upload-pack' standard error
  bytes stderr = 2;
  // This field may be nil. This is intentional: only when the remote
  // command has finished can we return its exit status.
  ExitStatus exit_status = 3;
}

message SSHReceivePackRequest {
  // 'repository' must be present in the first message.
  Repository repository = 1 [(target_repository)=true];
  // A chunk of raw data to be copied to 'git upload-pack' standard input
  bytes stdin = 2;
  // Contents of GL_ID, GL_REPOSITORY, and GL_USERNAME environment variables
  // for 'git receive-pack'
  string gl_id = 3;
  string gl_repository = 4;
  string gl_username = 5;

  // Git protocol version
  string git_protocol = 6;

  // Parameters to use with git -c (key=value pairs)
  repeated string git_config_options = 7;
}

message SSHReceivePackResponse {
  // A chunk of raw data from 'git receive-pack' standard output
  bytes stdout = 1;
  // A chunk of raw data from 'git receive-pack' standard error
  bytes stderr = 2;
  // This field may be nil. This is intentional: only when the remote
  // command has finished can we return its exit status.
  ExitStatus exit_status = 3;
}

message SSHUploadArchiveRequest {
  // 'repository' must be present in the first message.
  Repository repository = 1 [(target_repository)=true];
  // A chunk of raw data to be copied to 'git upload-archive' standard input
  bytes stdin = 2;
}

message SSHUploadArchiveResponse {
  // A chunk of raw data from 'git upload-archive' standard output
  bytes stdout = 1;
  // A chunk of raw data from 'git upload-archive' standard error
  bytes stderr = 2;
  // This value will only be set on the last message
  ExitStatus exit_status = 3;
}