Database governance built for humans and agents — controlling changes and access across every major database.
Go cicddata-governancedata-maskingdata-securitydatabase-accessdatabase-governancedevopsdevsecopsflywaygitopsliquibasemongodbmysqloraclepostgresqlschema-migrationssecuritysql-clientsqlservertidb
chore: implement ssh config api/store (#5822)
Danny Xu058389292e74
diff --git a/backend/api/v1/instance_service.go b/backend/api/v1/instance_service.goindex 4c5e3760bf..1ee740e92d 100644--- a/backend/api/v1/instance_service.go+++ b/backend/api/v1/instance_service.go@@ -572,20 +572,25 @@ func (s *InstanceService) convertToDataSourceMessage(dataSource *v1pb.DataSource}return &store.DataSourceMessage{- Title: dataSource.Title,- Type: dsType,- Username: dataSource.Username,- ObfuscatedPassword: common.Obfuscate(dataSource.Password, s.secret),- ObfuscatedSslCa: common.Obfuscate(dataSource.SslCa, s.secret),- ObfuscatedSslCert: common.Obfuscate(dataSource.SslCert, s.secret),- ObfuscatedSslKey: common.Obfuscate(dataSource.SslKey, s.secret),- Host: dataSource.Host,- Port: dataSource.Port,- Database: dataSource.Database,- SRV: dataSource.Srv,- AuthenticationDatabase: dataSource.AuthenticationDatabase,- SID: dataSource.Sid,- ServiceName: dataSource.ServiceName,+ Title: dataSource.Title,+ Type: dsType,+ Username: dataSource.Username,+ ObfuscatedPassword: common.Obfuscate(dataSource.Password, s.secret),+ ObfuscatedSslCa: common.Obfuscate(dataSource.SslCa, s.secret),+ ObfuscatedSslCert: common.Obfuscate(dataSource.SslCert, s.secret),+ ObfuscatedSslKey: common.Obfuscate(dataSource.SslKey, s.secret),+ Host: dataSource.Host,+ Port: dataSource.Port,+ Database: dataSource.Database,+ SRV: dataSource.Srv,+ AuthenticationDatabase: dataSource.AuthenticationDatabase,+ SID: dataSource.Sid,+ ServiceName: dataSource.ServiceName,+ SSHHost: dataSource.SshHost,+ SSHPort: dataSource.SshPort,+ SSHUser: dataSource.SshUser,+ SSHObfuscatedPassword: common.Obfuscate(dataSource.SshPassword, s.secret),+ SSHObfuscatedPrivateKey: common.Obfuscate(dataSource.SshPrivateKey, s.secret),}, nil}diff --git a/backend/component/dbfactory/dbfactory.go b/backend/component/dbfactory/dbfactory.goindex c81c8e6967..7774d56f7e 100644--- a/backend/component/dbfactory/dbfactory.go+++ b/backend/component/dbfactory/dbfactory.go@@ -151,6 +151,7 @@ func (d *DBFactory) GetReadOnlyDatabaseDriver(ctx context.Context, instance *stoif err != nil {return nil, err}+ // TODO(d): fill in SSH config.driver, err := getDatabaseDriver(ctx,instance.Engine,diff --git a/backend/legacyapi/data_source.go b/backend/legacyapi/data_source.goindex be066b6310..41960d590f 100644--- a/backend/legacyapi/data_source.go+++ b/backend/legacyapi/data_source.go@@ -42,8 +42,13 @@ type DataSourceOptions struct {// AuthenticationDatabase is used for MongoDB only.AuthenticationDatabase string `json:"authenticationDatabase" jsonapi:"attr,authenticationDatabase"`// SID and ServiceName are used for Oracle.- SID string `json:"sid" jsonapi:"attr,sid"`- ServiceName string `json:"serviceName" jsonapi:"attr,serviceName"`+ SID string `json:"sid" jsonapi:"attr,sid"`+ ServiceName string `json:"serviceName" jsonapi:"attr,serviceName"`+ SSHHost string `json:"sshHost" jsonapi:"attr,sshHost"`+ SSHPort string `json:"sshPort" jsonapi:"attr,sshPort"`+ SSHUser string `json:"sshUser" jsonapi:"attr,sshUser"`+ SSHPassword string `json:"sshPassword" jsonapi:"attr,sshPassword"`+ SSHPrivateKey string `json:"sshPrivateKey" jsonapi:"attr,sshPrivateKey"`}// getDefaultDataSourceOptions returns the default data source options.diff --git a/backend/legacyapi/instance.go b/backend/legacyapi/instance.goindex 2fdeea225a..22e0d6468d 100644--- a/backend/legacyapi/instance.go+++ b/backend/legacyapi/instance.go@@ -56,8 +56,13 @@ type InstanceCreate struct {// AuthenticationDatabase is used for MongoDB only.AuthenticationDatabase string `jsonapi:"attr,authenticationDatabase"`// SID and ServiceName are used for Oracle.- SID string `jsonapi:"attr,sid"`- ServiceName string `jsonapi:"attr,serviceName"`+ SID string `jsonapi:"attr,sid"`+ ServiceName string `jsonapi:"attr,serviceName"`+ SSHHost string `json:"sshHost" jsonapi:"attr,sshHost"`+ SSHPort string `json:"sshPort" jsonapi:"attr,sshPort"`+ SSHUser string `json:"sshUser" jsonapi:"attr,sshUser"`+ SSHPassword string `json:"sshPassword" jsonapi:"attr,sshPassword"`+ SSHPrivateKey string `json:"sshPrivateKey" jsonapi:"attr,sshPrivateKey"`}// InstanceFind is the API message for finding instances.diff --git a/backend/server/database.go b/backend/server/database.goindex 916787bfc5..a7a637387b 100644--- a/backend/server/database.go+++ b/backend/server/database.go@@ -533,20 +533,25 @@ func (s *Server) registerDatabaseRoutes(g *echo.Group) {title = api.ReadOnlyDataSourceName}dataSourceMessage := &store.DataSourceMessage{- Title: title,- Type: dataSourceCreate.Type,- Username: dataSourceCreate.Username,- ObfuscatedPassword: common.Obfuscate(dataSourceCreate.Password, s.secret),- ObfuscatedSslCa: common.Obfuscate(dataSourceCreate.SslCa, s.secret),- ObfuscatedSslCert: common.Obfuscate(dataSourceCreate.SslCert, s.secret),- ObfuscatedSslKey: common.Obfuscate(dataSourceCreate.SslKey, s.secret),- Host: dataSourceCreate.Host,- Port: dataSourceCreate.Port,- Database: dataSourceCreate.Database,- SRV: dataSourceCreate.Options.SRV,- AuthenticationDatabase: dataSourceCreate.Options.AuthenticationDatabase,- SID: dataSourceCreate.Options.SID,- ServiceName: dataSourceCreate.Options.ServiceName,+ Title: title,+ Type: dataSourceCreate.Type,+ Username: dataSourceCreate.Username,+ ObfuscatedPassword: common.Obfuscate(dataSourceCreate.Password, s.secret),+ ObfuscatedSslCa: common.Obfuscate(dataSourceCreate.SslCa, s.secret),+ ObfuscatedSslCert: common.Obfuscate(dataSourceCreate.SslCert, s.secret),+ ObfuscatedSslKey: common.Obfuscate(dataSourceCreate.SslKey, s.secret),+ Host: dataSourceCreate.Host,+ Port: dataSourceCreate.Port,+ Database: dataSourceCreate.Database,+ SRV: dataSourceCreate.Options.SRV,+ AuthenticationDatabase: dataSourceCreate.Options.AuthenticationDatabase,+ SID: dataSourceCreate.Options.SID,+ ServiceName: dataSourceCreate.Options.ServiceName,+ SSHHost: dataSourceCreate.Options.SSHHost,+ SSHPort: dataSourceCreate.Options.SSHPort,+ SSHUser: dataSourceCreate.Options.SSHUser,+ SSHObfuscatedPassword: common.Obfuscate(dataSourceCreate.Options.SSHPassword, s.secret),+ SSHObfuscatedPrivateKey: common.Obfuscate(dataSourceCreate.Options.SSHPrivateKey, s.secret),}if err := s.store.AddDataSourceToInstanceV2(ctx, instance.UID, creatorID, instance.EnvironmentID, instance.ResourceID, dataSourceMessage); err != nil {return errdiff --git a/backend/server/instance.go b/backend/server/instance.goindex 8864ccdfbe..4164cf182e 100644--- a/backend/server/instance.go+++ b/backend/server/instance.go@@ -70,20 +70,25 @@ func (s *Server) registerInstanceRoutes(g *echo.Group) {ExternalLink: instanceCreate.ExternalLink,DataSources: []*store.DataSourceMessage{{- Title: api.AdminDataSourceName,- Type: api.Admin,- Username: instanceCreate.Username,- ObfuscatedPassword: common.Obfuscate(instanceCreate.Password, s.secret),- ObfuscatedSslCa: common.Obfuscate(instanceCreate.SslCa, s.secret),- ObfuscatedSslCert: common.Obfuscate(instanceCreate.SslCert, s.secret),- ObfuscatedSslKey: common.Obfuscate(instanceCreate.SslKey, s.secret),- Host: instanceCreate.Host,- Port: instanceCreate.Port,- Database: instanceCreate.Database,- SRV: instanceCreate.SRV,- AuthenticationDatabase: instanceCreate.AuthenticationDatabase,- SID: instanceCreate.SID,- ServiceName: instanceCreate.ServiceName,+ Title: api.AdminDataSourceName,+ Type: api.Admin,+ Username: instanceCreate.Username,+ ObfuscatedPassword: common.Obfuscate(instanceCreate.Password, s.secret),+ ObfuscatedSslCa: common.Obfuscate(instanceCreate.SslCa, s.secret),+ ObfuscatedSslCert: common.Obfuscate(instanceCreate.SslCert, s.secret),+ ObfuscatedSslKey: common.Obfuscate(instanceCreate.SslKey, s.secret),+ Host: instanceCreate.Host,+ Port: instanceCreate.Port,+ Database: instanceCreate.Database,+ SRV: instanceCreate.SRV,+ AuthenticationDatabase: instanceCreate.AuthenticationDatabase,+ SID: instanceCreate.SID,+ ServiceName: instanceCreate.ServiceName,+ SSHHost: instanceCreate.SSHHost,+ SSHPort: instanceCreate.SSHHost,+ SSHUser: instanceCreate.SSHHost,+ SSHObfuscatedPassword: common.Obfuscate(instanceCreate.SSHPassword, s.secret),+ SSHObfuscatedPrivateKey: common.Obfuscate(instanceCreate.SSHPrivateKey, s.secret),},},}, creator)diff --git a/backend/server/sql.go b/backend/server/sql.goindex 23895ae153..68ad9ea9db 100644--- a/backend/server/sql.go+++ b/backend/server/sql.go@@ -65,6 +65,7 @@ func (s *Server) registerSQLRoutes(g *echo.Group) {}}}+ // TODO(d): fill in ssh config.var tlsConfig db.TLSConfigsupportTLS := connectionInfo.Engine == db.ClickHouse || connectionInfo.Engine == db.MySQL || connectionInfo.Engine == db.TiDB || connectionInfo.Engine == db.MariaDB || connectionInfo.Engine == db.OceanBasediff --git a/backend/store/data_source.go b/backend/store/data_source.goindex f9788e542e..f9059012f2 100644--- a/backend/store/data_source.go+++ b/backend/store/data_source.go@@ -29,6 +29,12 @@ type DataSourceMessage struct {AuthenticationDatabase stringSID stringServiceName string+ // SSH related.+ SSHHost string+ SSHPort string+ SSHUser string+ SSHObfuscatedPassword string+ SSHObfuscatedPrivateKey string// (deprecated) Output only.UID intDatabaseID int@@ -56,6 +62,12 @@ type UpdateDataSourceMessage struct {AuthenticationDatabase *stringSID *stringServiceName *string+ // SSH related.+ SSHHost *string+ SSHPort *string+ SSHUser *string+ SSHObfuscatedPassword *string+ SSHObfuscatedPrivateKey *string}func (*Store) listDataSourceV2(ctx context.Context, tx *Tx, instanceID string) ([]*DataSourceMessage, error) {@@ -113,6 +125,11 @@ func (*Store) listDataSourceV2(ctx context.Context, tx *Tx, instanceID string) (dataSourceMessage.AuthenticationDatabase = dataSourceOptions.AuthenticationDatabasedataSourceMessage.SID = dataSourceOptions.SiddataSourceMessage.ServiceName = dataSourceOptions.ServiceName+ dataSourceMessage.SSHHost = dataSourceOptions.SshHost+ dataSourceMessage.SSHPort = dataSourceOptions.SshPort+ dataSourceMessage.SSHUser = dataSourceOptions.SshUser+ dataSourceMessage.SSHObfuscatedPassword = dataSourceOptions.SshObfuscatedPassword+ dataSourceMessage.SSHObfuscatedPrivateKey = dataSourceOptions.SshObfuscatedPrivateKeydataSourceMessages = append(dataSourceMessages, &dataSourceMessage)}@@ -230,6 +247,21 @@ func (s *Store) UpdateDataSourceV2(ctx context.Context, patch *UpdateDataSourceMif v := patch.ServiceName; v != nil {optionSet, args = append(optionSet, fmt.Sprintf("jsonb_build_object('serviceName', to_jsonb($%d::TEXT))", len(args)+1)), append(args, *v)}+ if v := patch.SSHHost; v != nil {+ optionSet, args = append(optionSet, fmt.Sprintf("jsonb_build_object('sshHost', to_jsonb($%d::TEXT))", len(args)+1)), append(args, *v)+ }+ if v := patch.SSHPort; v != nil {+ optionSet, args = append(optionSet, fmt.Sprintf("jsonb_build_object('sshPort', to_jsonb($%d::TEXT))", len(args)+1)), append(args, *v)+ }+ if v := patch.SSHUser; v != nil {+ optionSet, args = append(optionSet, fmt.Sprintf("jsonb_build_object('sshUser', to_jsonb($%d::TEXT))", len(args)+1)), append(args, *v)+ }+ if v := patch.SSHObfuscatedPassword; v != nil {+ optionSet, args = append(optionSet, fmt.Sprintf("jsonb_build_object('sshObfuscatedPassword', to_jsonb($%d::TEXT))", len(args)+1)), append(args, *v)+ }+ if v := patch.SSHObfuscatedPrivateKey; v != nil {+ optionSet, args = append(optionSet, fmt.Sprintf("jsonb_build_object('sshObfuscatedPrivateKey', to_jsonb($%d::TEXT))", len(args)+1)), append(args, *v)+ }if len(optionSet) != 0 {set = append(set, fmt.Sprintf(`options = options || %s`, strings.Join(optionSet, "||")))}@@ -269,10 +301,15 @@ func (s *Store) UpdateDataSourceV2(ctx context.Context, patch *UpdateDataSourceMfunc (*Store) addDataSourceToInstanceImplV2(ctx context.Context, tx *Tx, instanceUID, databaseUID, creatorID int, dataSource *DataSourceMessage) error {// We flatten the data source fields in DataSourceMessage, so we need to compose them in store layer before INSERT.dataSourceOptions := storepb.DataSourceOptions{- Srv: dataSource.SRV,- AuthenticationDatabase: dataSource.AuthenticationDatabase,- Sid: dataSource.SID,- ServiceName: dataSource.ServiceName,+ Srv: dataSource.SRV,+ AuthenticationDatabase: dataSource.AuthenticationDatabase,+ Sid: dataSource.SID,+ ServiceName: dataSource.ServiceName,+ SshHost: dataSource.SSHHost,+ SshPort: dataSource.SSHPort,+ SshUser: dataSource.SSHUser,+ SshObfuscatedPassword: dataSource.SSHObfuscatedPassword,+ SshObfuscatedPrivateKey: dataSource.SSHObfuscatedPrivateKey,}protoBytes, err := protojson.Marshal(&dataSourceOptions)if err != nil {diff --git a/frontend/src/types/proto/store/data_source.ts b/frontend/src/types/proto/store/data_source.tsindex d998399617..30566208f5 100644--- a/frontend/src/types/proto/store/data_source.ts+++ b/frontend/src/types/proto/store/data_source.ts@@ -11,23 +11,33 @@ export interface DataSourceOptions {/** sid and service_name are used for Oracle. */sid: string;serviceName: string;-}--export interface SSHConfig {- /** The hostname of the SSH server agent. */- host: string;+ /**+ * SSH related+ * The hostname of the SSH server agent.+ */+ sshHost: string;/** The port of the SSH server agent. It's 22 typically. */- port: string;+ sshPort: string;/** The user to login the server. */- user: string;+ sshUser: string;/** The password to login the server. If it's empty string, no password is required. */- password: string;+ sshObfuscatedPassword: string;/** The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK"). */- privateKey: string;+ sshObfuscatedPrivateKey: string;}function createBaseDataSourceOptions(): DataSourceOptions {- return { srv: false, authenticationDatabase: "", sid: "", serviceName: "" };+ return {+ srv: false,+ authenticationDatabase: "",+ sid: "",+ serviceName: "",+ sshHost: "",+ sshPort: "",+ sshUser: "",+ sshObfuscatedPassword: "",+ sshObfuscatedPrivateKey: "",+ };}export const DataSourceOptions = {@@ -44,6 +54,21 @@ export const DataSourceOptions = {if (message.serviceName !== "") {writer.uint32(34).string(message.serviceName);}+ if (message.sshHost !== "") {+ writer.uint32(42).string(message.sshHost);+ }+ if (message.sshPort !== "") {+ writer.uint32(50).string(message.sshPort);+ }+ if (message.sshUser !== "") {+ writer.uint32(58).string(message.sshUser);+ }+ if (message.sshObfuscatedPassword !== "") {+ writer.uint32(66).string(message.sshObfuscatedPassword);+ }+ if (message.sshObfuscatedPrivateKey !== "") {+ writer.uint32(74).string(message.sshObfuscatedPrivateKey);+ }return writer;},@@ -82,112 +107,40 @@ export const DataSourceOptions = {message.serviceName = reader.string();continue;- }- if ((tag & 7) == 4 || tag == 0) {- break;- }- reader.skipType(tag & 7);- }- return message;- },-- fromJSON(object: any): DataSourceOptions {- return {- srv: isSet(object.srv) ? Boolean(object.srv) : false,- authenticationDatabase: isSet(object.authenticationDatabase) ? String(object.authenticationDatabase) : "",- sid: isSet(object.sid) ? String(object.sid) : "",- serviceName: isSet(object.serviceName) ? String(object.serviceName) : "",- };- },-- toJSON(message: DataSourceOptions): unknown {- const obj: any = {};- message.srv !== undefined && (obj.srv = message.srv);- message.authenticationDatabase !== undefined && (obj.authenticationDatabase = message.authenticationDatabase);- message.sid !== undefined && (obj.sid = message.sid);- message.serviceName !== undefined && (obj.serviceName = message.serviceName);- return obj;- },-- create(base?: DeepPartial<DataSourceOptions>): DataSourceOptions {- return DataSourceOptions.fromPartial(base ?? {});- },-- fromPartial(object: DeepPartial<DataSourceOptions>): DataSourceOptions {- const message = createBaseDataSourceOptions();- message.srv = object.srv ?? false;- message.authenticationDatabase = object.authenticationDatabase ?? "";- message.sid = object.sid ?? "";- message.serviceName = object.serviceName ?? "";- return message;- },-};--function createBaseSSHConfig(): SSHConfig {- return { host: "", port: "", user: "", password: "", privateKey: "" };-}--export const SSHConfig = {- encode(message: SSHConfig, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {- if (message.host !== "") {- writer.uint32(10).string(message.host);- }- if (message.port !== "") {- writer.uint32(18).string(message.port);- }- if (message.user !== "") {- writer.uint32(26).string(message.user);- }- if (message.password !== "") {- writer.uint32(34).string(message.password);- }- if (message.privateKey !== "") {- writer.uint32(42).string(message.privateKey);- }- return writer;- },-- decode(input: _m0.Reader | Uint8Array, length?: number): SSHConfig {- const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);- let end = length === undefined ? reader.len : reader.pos + length;- const message = createBaseSSHConfig();- while (reader.pos < end) {- const tag = reader.uint32();- switch (tag >>> 3) {- case 1:- if (tag != 10) {+ case 5:+ if (tag != 42) {break;}- message.host = reader.string();+ message.sshHost = reader.string();continue;- case 2:- if (tag != 18) {+ case 6:+ if (tag != 50) {break;}- message.port = reader.string();+ message.sshPort = reader.string();continue;- case 3:- if (tag != 26) {+ case 7:+ if (tag != 58) {break;}- message.user = reader.string();+ message.sshUser = reader.string();continue;- case 4:- if (tag != 34) {+ case 8:+ if (tag != 66) {break;}- message.password = reader.string();+ message.sshObfuscatedPassword = reader.string();continue;- case 5:- if (tag != 42) {+ case 9:+ if (tag != 74) {break;}- message.privateKey = reader.string();+ message.sshObfuscatedPrivateKey = reader.string();continue;}if ((tag & 7) == 4 || tag == 0) {@@ -198,37 +151,49 @@ export const SSHConfig = {return message;},- fromJSON(object: any): SSHConfig {+ fromJSON(object: any): DataSourceOptions {return {- host: isSet(object.host) ? String(object.host) : "",- port: isSet(object.port) ? String(object.port) : "",- user: isSet(object.user) ? String(object.user) : "",- password: isSet(object.password) ? String(object.password) : "",- privateKey: isSet(object.privateKey) ? String(object.privateKey) : "",+ srv: isSet(object.srv) ? Boolean(object.srv) : false,+ authenticationDatabase: isSet(object.authenticationDatabase) ? String(object.authenticationDatabase) : "",+ sid: isSet(object.sid) ? String(object.sid) : "",+ serviceName: isSet(object.serviceName) ? String(object.serviceName) : "",+ sshHost: isSet(object.sshHost) ? String(object.sshHost) : "",+ sshPort: isSet(object.sshPort) ? String(object.sshPort) : "",+ sshUser: isSet(object.sshUser) ? String(object.sshUser) : "",+ sshObfuscatedPassword: isSet(object.sshObfuscatedPassword) ? String(object.sshObfuscatedPassword) : "",+ sshObfuscatedPrivateKey: isSet(object.sshObfuscatedPrivateKey) ? String(object.sshObfuscatedPrivateKey) : "",};},- toJSON(message: SSHConfig): unknown {+ toJSON(message: DataSourceOptions): unknown {const obj: any = {};- message.host !== undefined && (obj.host = message.host);- message.port !== undefined && (obj.port = message.port);- message.user !== undefined && (obj.user = message.user);- message.password !== undefined && (obj.password = message.password);- message.privateKey !== undefined && (obj.privateKey = message.privateKey);+ message.srv !== undefined && (obj.srv = message.srv);+ message.authenticationDatabase !== undefined && (obj.authenticationDatabase = message.authenticationDatabase);+ message.sid !== undefined && (obj.sid = message.sid);+ message.serviceName !== undefined && (obj.serviceName = message.serviceName);+ message.sshHost !== undefined && (obj.sshHost = message.sshHost);+ message.sshPort !== undefined && (obj.sshPort = message.sshPort);+ message.sshUser !== undefined && (obj.sshUser = message.sshUser);+ message.sshObfuscatedPassword !== undefined && (obj.sshObfuscatedPassword = message.sshObfuscatedPassword);+ message.sshObfuscatedPrivateKey !== undefined && (obj.sshObfuscatedPrivateKey = message.sshObfuscatedPrivateKey);return obj;},- create(base?: DeepPartial<SSHConfig>): SSHConfig {- return SSHConfig.fromPartial(base ?? {});+ create(base?: DeepPartial<DataSourceOptions>): DataSourceOptions {+ return DataSourceOptions.fromPartial(base ?? {});},- fromPartial(object: DeepPartial<SSHConfig>): SSHConfig {- const message = createBaseSSHConfig();- message.host = object.host ?? "";- message.port = object.port ?? "";- message.user = object.user ?? "";- message.password = object.password ?? "";- message.privateKey = object.privateKey ?? "";+ fromPartial(object: DeepPartial<DataSourceOptions>): DataSourceOptions {+ const message = createBaseDataSourceOptions();+ message.srv = object.srv ?? false;+ message.authenticationDatabase = object.authenticationDatabase ?? "";+ message.sid = object.sid ?? "";+ message.serviceName = object.serviceName ?? "";+ message.sshHost = object.sshHost ?? "";+ message.sshPort = object.sshPort ?? "";+ message.sshUser = object.sshUser ?? "";+ message.sshObfuscatedPassword = object.sshObfuscatedPassword ?? "";+ message.sshObfuscatedPrivateKey = object.sshObfuscatedPrivateKey ?? "";return message;},};diff --git a/frontend/src/types/proto/v1/instance_service.ts b/frontend/src/types/proto/v1/instance_service.tsindex b84f2178b7..367a676a44 100644--- a/frontend/src/types/proto/v1/instance_service.ts+++ b/frontend/src/types/proto/v1/instance_service.ts@@ -214,30 +214,26 @@ export interface DataSource {/** sid and service_name are used for Oracle. */sid: string;serviceName: string;- /** Connection over SSH. */- sshConfig?: SSHConfig;-}--export interface SSHConfig {/**+ * Connection over SSH.* The hostname of the SSH server agent.* Required.*/- host: string;+ sshHost: string;/*** The port of the SSH server agent. It's 22 typically.* Required.*/- port: string;+ sshPort: string;/*** The user to login the server.* Required.*/- user: string;+ sshUser: string;/** The password to login the server. If it's empty string, no password is required. */- password: string;+ sshPassword: string;/** The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK"). */- privateKey: string;+ sshPrivateKey: string;}function createBaseGetInstanceRequest(): GetInstanceRequest {@@ -1186,7 +1182,11 @@ function createBaseDataSource(): DataSource {authenticationDatabase: "",sid: "",serviceName: "",- sshConfig: undefined,+ sshHost: "",+ sshPort: "",+ sshUser: "",+ sshPassword: "",+ sshPrivateKey: "",};}@@ -1234,8 +1234,20 @@ export const DataSource = {if (message.serviceName !== "") {writer.uint32(114).string(message.serviceName);}- if (message.sshConfig !== undefined) {- SSHConfig.encode(message.sshConfig, writer.uint32(122).fork()).ldelim();+ if (message.sshHost !== "") {+ writer.uint32(122).string(message.sshHost);+ }+ if (message.sshPort !== "") {+ writer.uint32(130).string(message.sshPort);+ }+ if (message.sshUser !== "") {+ writer.uint32(138).string(message.sshUser);+ }+ if (message.sshPassword !== "") {+ writer.uint32(146).string(message.sshPassword);+ }+ if (message.sshPrivateKey !== "") {+ writer.uint32(154).string(message.sshPrivateKey);}return writer;},@@ -1350,7 +1362,35 @@ export const DataSource = {break;}- message.sshConfig = SSHConfig.decode(reader, reader.uint32());+ message.sshHost = reader.string();+ continue;+ case 16:+ if (tag != 130) {+ break;+ }++ message.sshPort = reader.string();+ continue;+ case 17:+ if (tag != 138) {+ break;+ }++ message.sshUser = reader.string();+ continue;+ case 18:+ if (tag != 146) {+ break;+ }++ message.sshPassword = reader.string();+ continue;+ case 19:+ if (tag != 154) {+ break;+ }++ message.sshPrivateKey = reader.string();continue;}if ((tag & 7) == 4 || tag == 0) {@@ -1377,7 +1417,11 @@ export const DataSource = {authenticationDatabase: isSet(object.authenticationDatabase) ? String(object.authenticationDatabase) : "",sid: isSet(object.sid) ? String(object.sid) : "",serviceName: isSet(object.serviceName) ? String(object.serviceName) : "",- sshConfig: isSet(object.sshConfig) ? SSHConfig.fromJSON(object.sshConfig) : undefined,+ sshHost: isSet(object.sshHost) ? String(object.sshHost) : "",+ sshPort: isSet(object.sshPort) ? String(object.sshPort) : "",+ sshUser: isSet(object.sshUser) ? String(object.sshUser) : "",+ sshPassword: isSet(object.sshPassword) ? String(object.sshPassword) : "",+ sshPrivateKey: isSet(object.sshPrivateKey) ? String(object.sshPrivateKey) : "",};},@@ -1397,8 +1441,11 @@ export const DataSource = {message.authenticationDatabase !== undefined && (obj.authenticationDatabase = message.authenticationDatabase);message.sid !== undefined && (obj.sid = message.sid);message.serviceName !== undefined && (obj.serviceName = message.serviceName);- message.sshConfig !== undefined &&- (obj.sshConfig = message.sshConfig ? SSHConfig.toJSON(message.sshConfig) : undefined);+ message.sshHost !== undefined && (obj.sshHost = message.sshHost);+ message.sshPort !== undefined && (obj.sshPort = message.sshPort);+ message.sshUser !== undefined && (obj.sshUser = message.sshUser);+ message.sshPassword !== undefined && (obj.sshPassword = message.sshPassword);+ message.sshPrivateKey !== undefined && (obj.sshPrivateKey = message.sshPrivateKey);return obj;},@@ -1422,119 +1469,11 @@ export const DataSource = {message.authenticationDatabase = object.authenticationDatabase ?? "";message.sid = object.sid ?? "";message.serviceName = object.serviceName ?? "";- message.sshConfig = (object.sshConfig !== undefined && object.sshConfig !== null)- ? SSHConfig.fromPartial(object.sshConfig)- : undefined;- return message;- },-};--function createBaseSSHConfig(): SSHConfig {- return { host: "", port: "", user: "", password: "", privateKey: "" };-}--export const SSHConfig = {- encode(message: SSHConfig, writer: _m0.Writer = _m0.Writer.create()): _m0.Writer {- if (message.host !== "") {- writer.uint32(10).string(message.host);- }- if (message.port !== "") {- writer.uint32(18).string(message.port);- }- if (message.user !== "") {- writer.uint32(26).string(message.user);- }- if (message.password !== "") {- writer.uint32(34).string(message.password);- }- if (message.privateKey !== "") {- writer.uint32(42).string(message.privateKey);- }- return writer;- },-- decode(input: _m0.Reader | Uint8Array, length?: number): SSHConfig {- const reader = input instanceof _m0.Reader ? input : _m0.Reader.create(input);- let end = length === undefined ? reader.len : reader.pos + length;- const message = createBaseSSHConfig();- while (reader.pos < end) {- const tag = reader.uint32();- switch (tag >>> 3) {- case 1:- if (tag != 10) {- break;- }-- message.host = reader.string();- continue;- case 2:- if (tag != 18) {- break;- }-- message.port = reader.string();- continue;- case 3:- if (tag != 26) {- break;- }-- message.user = reader.string();- continue;- case 4:- if (tag != 34) {- break;- }-- message.password = reader.string();- continue;- case 5:- if (tag != 42) {- break;- }-- message.privateKey = reader.string();- continue;- }- if ((tag & 7) == 4 || tag == 0) {- break;- }- reader.skipType(tag & 7);- }- return message;- },-- fromJSON(object: any): SSHConfig {- return {- host: isSet(object.host) ? String(object.host) : "",- port: isSet(object.port) ? String(object.port) : "",- user: isSet(object.user) ? String(object.user) : "",- password: isSet(object.password) ? String(object.password) : "",- privateKey: isSet(object.privateKey) ? String(object.privateKey) : "",- };- },-- toJSON(message: SSHConfig): unknown {- const obj: any = {};- message.host !== undefined && (obj.host = message.host);- message.port !== undefined && (obj.port = message.port);- message.user !== undefined && (obj.user = message.user);- message.password !== undefined && (obj.password = message.password);- message.privateKey !== undefined && (obj.privateKey = message.privateKey);- return obj;- },-- create(base?: DeepPartial<SSHConfig>): SSHConfig {- return SSHConfig.fromPartial(base ?? {});- },-- fromPartial(object: DeepPartial<SSHConfig>): SSHConfig {- const message = createBaseSSHConfig();- message.host = object.host ?? "";- message.port = object.port ?? "";- message.user = object.user ?? "";- message.password = object.password ?? "";- message.privateKey = object.privateKey ?? "";+ message.sshHost = object.sshHost ?? "";+ message.sshPort = object.sshPort ?? "";+ message.sshUser = object.sshUser ?? "";+ message.sshPassword = object.sshPassword ?? "";+ message.sshPrivateKey = object.sshPrivateKey ?? "";return message;},};diff --git a/proto/gen/grpc-doc/store/README.md b/proto/gen/grpc-doc/store/README.mdindex 8ae878b791..df815ce592 100644--- a/proto/gen/grpc-doc/store/README.md+++ b/proto/gen/grpc-doc/store/README.md@@ -29,7 +29,6 @@- [store/data_source.proto](#store_data_source-proto)- [DataSourceOptions](#bytebase-store-DataSourceOptions)- - [SSHConfig](#bytebase-store-SSHConfig)- [store/database.proto](#store_database-proto)- [ColumnMetadata](#bytebase-store-ColumnMetadata)@@ -425,25 +424,11 @@ ANY means approving any node will proceed.| authentication_database | [string](#string) | | authentication_database is the database name to authenticate against, which stores the user credentials. || sid | [string](#string) | | sid and service_name are used for Oracle. || service_name | [string](#string) | | |-------<a name="bytebase-store-SSHConfig"></a>--### SSHConfig----| Field | Type | Label | Description |-| ----- | ---- | ----- | ----------- |-| host | [string](#string) | | The hostname of the SSH server agent. |-| port | [string](#string) | | The port of the SSH server agent. It's 22 typically. |-| user | [string](#string) | | The user to login the server. |-| password | [string](#string) | | The password to login the server. If it's empty string, no password is required. |-| private_key | [string](#string) | | The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK"). |+| ssh_host | [string](#string) | | SSH related The hostname of the SSH server agent. |+| ssh_port | [string](#string) | | The port of the SSH server agent. It's 22 typically. |+| ssh_user | [string](#string) | | The user to login the server. |+| ssh_obfuscated_password | [string](#string) | | The password to login the server. If it's empty string, no password is required. |+| ssh_obfuscated_private_key | [string](#string) | | The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK"). |diff --git a/proto/gen/grpc-doc/v1/README.md b/proto/gen/grpc-doc/v1/README.mdindex 815c507731..ec66e4be67 100644--- a/proto/gen/grpc-doc/v1/README.md+++ b/proto/gen/grpc-doc/v1/README.md@@ -184,7 +184,6 @@- [ListInstancesRequest](#bytebase-v1-ListInstancesRequest)- [ListInstancesResponse](#bytebase-v1-ListInstancesResponse)- [RemoveDataSourceRequest](#bytebase-v1-RemoveDataSourceRequest)- - [SSHConfig](#bytebase-v1-SSHConfig)- [SyncSlowQueriesRequest](#bytebase-v1-SyncSlowQueriesRequest)- [UndeleteInstanceRequest](#bytebase-v1-UndeleteInstanceRequest)- [UpdateDataSourceRequest](#bytebase-v1-UpdateDataSourceRequest)@@ -2858,7 +2857,11 @@ This value should be 4-63 characters, and valid characters are /[a-z][0-9]-/. || authentication_database | [string](#string) | | || sid | [string](#string) | | sid and service_name are used for Oracle. || service_name | [string](#string) | | |-| ssh_config | [SSHConfig](#bytebase-v1-SSHConfig) | | Connection over SSH. |+| ssh_host | [string](#string) | | Connection over SSH. The hostname of the SSH server agent. Required. |+| ssh_port | [string](#string) | | The port of the SSH server agent. It's 22 typically. Required. |+| ssh_user | [string](#string) | | The user to login the server. Required. |+| ssh_password | [string](#string) | | The password to login the server. If it's empty string, no password is required. |+| ssh_private_key | [string](#string) | | The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK"). |@@ -2968,25 +2971,6 @@ When paginating, all other parameters provided to `ListInstances` must match the-<a name="bytebase-v1-SSHConfig"></a>--### SSHConfig----| Field | Type | Label | Description |-| ----- | ---- | ----- | ----------- |-| host | [string](#string) | | The hostname of the SSH server agent. Required. |-| port | [string](#string) | | The port of the SSH server agent. It's 22 typically. Required. |-| user | [string](#string) | | The user to login the server. Required. |-| password | [string](#string) | | The password to login the server. If it's empty string, no password is required. |-| private_key | [string](#string) | | The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK"). |------<a name="bytebase-v1-SyncSlowQueriesRequest"></a>### SyncSlowQueriesRequestdiff --git a/proto/generated-go/store/data_source.pb.go b/proto/generated-go/store/data_source.pb.goindex 5b2ca21828..f40a1e2a5f 100644--- a/proto/generated-go/store/data_source.pb.go+++ b/proto/generated-go/store/data_source.pb.go@@ -32,6 +32,17 @@ type DataSourceOptions struct {// sid and service_name are used for Oracle.Sid string `protobuf:"bytes,3,opt,name=sid,proto3" json:"sid,omitempty"`ServiceName string `protobuf:"bytes,4,opt,name=service_name,json=serviceName,proto3" json:"service_name,omitempty"`+ // SSH related+ // The hostname of the SSH server agent.+ SshHost string `protobuf:"bytes,5,opt,name=ssh_host,json=sshHost,proto3" json:"ssh_host,omitempty"`+ // The port of the SSH server agent. It's 22 typically.+ SshPort string `protobuf:"bytes,6,opt,name=ssh_port,json=sshPort,proto3" json:"ssh_port,omitempty"`+ // The user to login the server.+ SshUser string `protobuf:"bytes,7,opt,name=ssh_user,json=sshUser,proto3" json:"ssh_user,omitempty"`+ // The password to login the server. If it's empty string, no password is required.+ SshObfuscatedPassword string `protobuf:"bytes,8,opt,name=ssh_obfuscated_password,json=sshObfuscatedPassword,proto3" json:"ssh_obfuscated_password,omitempty"`+ // The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK").+ SshObfuscatedPrivateKey string `protobuf:"bytes,9,opt,name=ssh_obfuscated_private_key,json=sshObfuscatedPrivateKey,proto3" json:"ssh_obfuscated_private_key,omitempty"`}func (x *DataSourceOptions) Reset() {@@ -94,86 +105,37 @@ func (x *DataSourceOptions) GetServiceName() string {return ""}-type SSHConfig struct {- state protoimpl.MessageState- sizeCache protoimpl.SizeCache- unknownFields protoimpl.UnknownFields-- // The hostname of the SSH server agent.- Host string `protobuf:"bytes,1,opt,name=host,proto3" json:"host,omitempty"`- // The port of the SSH server agent. It's 22 typically.- Port string `protobuf:"bytes,2,opt,name=port,proto3" json:"port,omitempty"`- // The user to login the server.- User string `protobuf:"bytes,3,opt,name=user,proto3" json:"user,omitempty"`- // The password to login the server. If it's empty string, no password is required.- Password string `protobuf:"bytes,4,opt,name=password,proto3" json:"password,omitempty"`- // The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK").- PrivateKey string `protobuf:"bytes,5,opt,name=private_key,json=privateKey,proto3" json:"private_key,omitempty"`-}--func (x *SSHConfig) Reset() {- *x = SSHConfig{}- if protoimpl.UnsafeEnabled {- mi := &file_store_data_source_proto_msgTypes[1]- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))- ms.StoreMessageInfo(mi)- }-}--func (x *SSHConfig) String() string {- return protoimpl.X.MessageStringOf(x)-}--func (*SSHConfig) ProtoMessage() {}--func (x *SSHConfig) ProtoReflect() protoreflect.Message {- mi := &file_store_data_source_proto_msgTypes[1]- if protoimpl.UnsafeEnabled && x != nil {- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))- if ms.LoadMessageInfo() == nil {- ms.StoreMessageInfo(mi)- }- return ms- }- return mi.MessageOf(x)-}--// Deprecated: Use SSHConfig.ProtoReflect.Descriptor instead.-func (*SSHConfig) Descriptor() ([]byte, []int) {- return file_store_data_source_proto_rawDescGZIP(), []int{1}-}--func (x *SSHConfig) GetHost() string {+func (x *DataSourceOptions) GetSshHost() string {if x != nil {- return x.Host+ return x.SshHost}return ""}-func (x *SSHConfig) GetPort() string {+func (x *DataSourceOptions) GetSshPort() string {if x != nil {- return x.Port+ return x.SshPort}return ""}-func (x *SSHConfig) GetUser() string {+func (x *DataSourceOptions) GetSshUser() string {if x != nil {- return x.User+ return x.SshUser}return ""}-func (x *SSHConfig) GetPassword() string {+func (x *DataSourceOptions) GetSshObfuscatedPassword() string {if x != nil {- return x.Password+ return x.SshObfuscatedPassword}return ""}-func (x *SSHConfig) GetPrivateKey() string {+func (x *DataSourceOptions) GetSshObfuscatedPrivateKey() string {if x != nil {- return x.PrivateKey+ return x.SshObfuscatedPrivateKey}return ""}@@ -183,7 +145,7 @@ var File_store_data_source_proto protoreflect.FileDescriptorvar file_store_data_source_proto_rawDesc = []byte{0x0a, 0x17, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x2f, 0x64, 0x61, 0x74, 0x61, 0x5f, 0x73, 0x6f, 0x75,0x72, 0x63, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x0e, 0x62, 0x79, 0x74, 0x65, 0x62,- 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x22, 0x93, 0x01, 0x0a, 0x11, 0x44, 0x61,+ 0x61, 0x73, 0x65, 0x2e, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x22, 0xd9, 0x02, 0x0a, 0x11, 0x44, 0x61,0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x4f, 0x70, 0x74, 0x69, 0x6f, 0x6e, 0x73, 0x12,0x10, 0x0a, 0x03, 0x73, 0x72, 0x76, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x03, 0x73, 0x72,0x76, 0x12, 0x37, 0x0a, 0x17, 0x61, 0x75, 0x74, 0x68, 0x65, 0x6e, 0x74, 0x69, 0x63, 0x61, 0x74,@@ -192,18 +154,22 @@ var file_store_data_source_proto_rawDesc = []byte{0x6f, 0x6e, 0x44, 0x61, 0x74, 0x61, 0x62, 0x61, 0x73, 0x65, 0x12, 0x10, 0x0a, 0x03, 0x73, 0x69,0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x73, 0x69, 0x64, 0x12, 0x21, 0x0a, 0x0c,0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x04, 0x20, 0x01,- 0x28, 0x09, 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x22,- 0x84, 0x01, 0x0a, 0x09, 0x53, 0x53, 0x48, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x12, 0x0a,- 0x04, 0x68, 0x6f, 0x73, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x68, 0x6f, 0x73,- 0x74, 0x12, 0x12, 0x0a, 0x04, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52,- 0x04, 0x70, 0x6f, 0x72, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x75, 0x73, 0x65, 0x72, 0x18, 0x03, 0x20,- 0x01, 0x28, 0x09, 0x52, 0x04, 0x75, 0x73, 0x65, 0x72, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x73,- 0x73, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x73,- 0x73, 0x77, 0x6f, 0x72, 0x64, 0x12, 0x1f, 0x0a, 0x0b, 0x70, 0x72, 0x69, 0x76, 0x61, 0x74, 0x65,- 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, 0x72, 0x69, 0x76,- 0x61, 0x74, 0x65, 0x4b, 0x65, 0x79, 0x42, 0x14, 0x5a, 0x12, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61,- 0x74, 0x65, 0x64, 0x2d, 0x67, 0x6f, 0x2f, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x62, 0x06, 0x70, 0x72,- 0x6f, 0x74, 0x6f, 0x33,+ 0x28, 0x09, 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4e, 0x61, 0x6d, 0x65, 0x12,+ 0x19, 0x0a, 0x08, 0x73, 0x73, 0x68, 0x5f, 0x68, 0x6f, 0x73, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28,+ 0x09, 0x52, 0x07, 0x73, 0x73, 0x68, 0x48, 0x6f, 0x73, 0x74, 0x12, 0x19, 0x0a, 0x08, 0x73, 0x73,+ 0x68, 0x5f, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x06, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x73,+ 0x68, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x19, 0x0a, 0x08, 0x73, 0x73, 0x68, 0x5f, 0x75, 0x73, 0x65,+ 0x72, 0x18, 0x07, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x73, 0x68, 0x55, 0x73, 0x65, 0x72,+ 0x12, 0x36, 0x0a, 0x17, 0x73, 0x73, 0x68, 0x5f, 0x6f, 0x62, 0x66, 0x75, 0x73, 0x63, 0x61, 0x74,+ 0x65, 0x64, 0x5f, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x08, 0x20, 0x01, 0x28,+ 0x09, 0x52, 0x15, 0x73, 0x73, 0x68, 0x4f, 0x62, 0x66, 0x75, 0x73, 0x63, 0x61, 0x74, 0x65, 0x64,+ 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x12, 0x3b, 0x0a, 0x1a, 0x73, 0x73, 0x68, 0x5f,+ 0x6f, 0x62, 0x66, 0x75, 0x73, 0x63, 0x61, 0x74, 0x65, 0x64, 0x5f, 0x70, 0x72, 0x69, 0x76, 0x61,+ 0x74, 0x65, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x09, 0x20, 0x01, 0x28, 0x09, 0x52, 0x17, 0x73, 0x73,+ 0x68, 0x4f, 0x62, 0x66, 0x75, 0x73, 0x63, 0x61, 0x74, 0x65, 0x64, 0x50, 0x72, 0x69, 0x76, 0x61,+ 0x74, 0x65, 0x4b, 0x65, 0x79, 0x42, 0x14, 0x5a, 0x12, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74,+ 0x65, 0x64, 0x2d, 0x67, 0x6f, 0x2f, 0x73, 0x74, 0x6f, 0x72, 0x65, 0x62, 0x06, 0x70, 0x72, 0x6f,+ 0x74, 0x6f, 0x33,}var (@@ -218,10 +184,9 @@ func file_store_data_source_proto_rawDescGZIP() []byte {return file_store_data_source_proto_rawDescData}-var file_store_data_source_proto_msgTypes = make([]protoimpl.MessageInfo, 2)+var file_store_data_source_proto_msgTypes = make([]protoimpl.MessageInfo, 1)var file_store_data_source_proto_goTypes = []interface{}{(*DataSourceOptions)(nil), // 0: bytebase.store.DataSourceOptions- (*SSHConfig)(nil), // 1: bytebase.store.SSHConfig}var file_store_data_source_proto_depIdxs = []int32{0, // [0:0] is the sub-list for method output_type@@ -249,18 +214,6 @@ func file_store_data_source_proto_init() {return nil}}- file_store_data_source_proto_msgTypes[1].Exporter = func(v interface{}, i int) interface{} {- switch v := v.(*SSHConfig); i {- case 0:- return &v.state- case 1:- return &v.sizeCache- case 2:- return &v.unknownFields- default:- return nil- }- }}type x struct{}out := protoimpl.TypeBuilder{@@ -268,7 +221,7 @@ func file_store_data_source_proto_init() {GoPackagePath: reflect.TypeOf(x{}).PkgPath(),RawDescriptor: file_store_data_source_proto_rawDesc,NumEnums: 0,- NumMessages: 2,+ NumMessages: 1,NumExtensions: 0,NumServices: 0,},diff --git a/proto/generated-go/v1/instance_service.pb.go b/proto/generated-go/v1/instance_service.pb.goindex fbc8ea0f21..86a6206512 100644--- a/proto/generated-go/v1/instance_service.pb.go+++ b/proto/generated-go/v1/instance_service.pb.go@@ -846,7 +846,19 @@ type DataSource struct {Sid string `protobuf:"bytes,13,opt,name=sid,proto3" json:"sid,omitempty"`ServiceName string `protobuf:"bytes,14,opt,name=service_name,json=serviceName,proto3" json:"service_name,omitempty"`// Connection over SSH.- SshConfig *SSHConfig `protobuf:"bytes,15,opt,name=ssh_config,json=sshConfig,proto3" json:"ssh_config,omitempty"`+ // The hostname of the SSH server agent.+ // Required.+ SshHost string `protobuf:"bytes,15,opt,name=ssh_host,json=sshHost,proto3" json:"ssh_host,omitempty"`+ // The port of the SSH server agent. It's 22 typically.+ // Required.+ SshPort string `protobuf:"bytes,16,opt,name=ssh_port,json=sshPort,proto3" json:"ssh_port,omitempty"`+ // The user to login the server.+ // Required.+ SshUser string `protobuf:"bytes,17,opt,name=ssh_user,json=sshUser,proto3" json:"ssh_user,omitempty"`+ // The password to login the server. If it's empty string, no password is required.+ SshPassword string `protobuf:"bytes,18,opt,name=ssh_password,json=sshPassword,proto3" json:"ssh_password,omitempty"`+ // The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK").+ SshPrivateKey string `protobuf:"bytes,19,opt,name=ssh_private_key,json=sshPrivateKey,proto3" json:"ssh_private_key,omitempty"`}func (x *DataSource) Reset() {@@ -979,96 +991,37 @@ func (x *DataSource) GetServiceName() string {return ""}-func (x *DataSource) GetSshConfig() *SSHConfig {- if x != nil {- return x.SshConfig- }- return nil-}--type SSHConfig struct {- state protoimpl.MessageState- sizeCache protoimpl.SizeCache- unknownFields protoimpl.UnknownFields-- // The hostname of the SSH server agent.- // Required.- Host string `protobuf:"bytes,1,opt,name=host,proto3" json:"host,omitempty"`- // The port of the SSH server agent. It's 22 typically.- // Required.- Port string `protobuf:"bytes,2,opt,name=port,proto3" json:"port,omitempty"`- // The user to login the server.- // Required.- User string `protobuf:"bytes,3,opt,name=user,proto3" json:"user,omitempty"`- // The password to login the server. If it's empty string, no password is required.- Password string `protobuf:"bytes,4,opt,name=password,proto3" json:"password,omitempty"`- // The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK").- PrivateKey string `protobuf:"bytes,5,opt,name=private_key,json=privateKey,proto3" json:"private_key,omitempty"`-}--func (x *SSHConfig) Reset() {- *x = SSHConfig{}- if protoimpl.UnsafeEnabled {- mi := &file_v1_instance_service_proto_msgTypes[13]- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))- ms.StoreMessageInfo(mi)- }-}--func (x *SSHConfig) String() string {- return protoimpl.X.MessageStringOf(x)-}--func (*SSHConfig) ProtoMessage() {}--func (x *SSHConfig) ProtoReflect() protoreflect.Message {- mi := &file_v1_instance_service_proto_msgTypes[13]- if protoimpl.UnsafeEnabled && x != nil {- ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))- if ms.LoadMessageInfo() == nil {- ms.StoreMessageInfo(mi)- }- return ms- }- return mi.MessageOf(x)-}--// Deprecated: Use SSHConfig.ProtoReflect.Descriptor instead.-func (*SSHConfig) Descriptor() ([]byte, []int) {- return file_v1_instance_service_proto_rawDescGZIP(), []int{13}-}--func (x *SSHConfig) GetHost() string {+func (x *DataSource) GetSshHost() string {if x != nil {- return x.Host+ return x.SshHost}return ""}-func (x *SSHConfig) GetPort() string {+func (x *DataSource) GetSshPort() string {if x != nil {- return x.Port+ return x.SshPort}return ""}-func (x *SSHConfig) GetUser() string {+func (x *DataSource) GetSshUser() string {if x != nil {- return x.User+ return x.SshUser}return ""}-func (x *SSHConfig) GetPassword() string {+func (x *DataSource) GetSshPassword() string {if x != nil {- return x.Password+ return x.SshPassword}return ""}-func (x *SSHConfig) GetPrivateKey() string {+func (x *DataSource) GetSshPrivateKey() string {if x != nil {- return x.PrivateKey+ return x.SshPrivateKey}return ""}@@ -1180,7 +1133,7 @@ var file_v1_instance_service_proto_rawDesc = []byte{0x6f, 0x75, 0x72, 0x63, 0x65, 0x73, 0x18, 0x07, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x17, 0x2e, 0x62,0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x61, 0x74, 0x61, 0x53,0x6f, 0x75, 0x72, 0x63, 0x65, 0x52, 0x0b, 0x64, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63,- 0x65, 0x73, 0x22, 0xe5, 0x03, 0x0a, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63,+ 0x65, 0x73, 0x22, 0xd4, 0x04, 0x0a, 0x0a, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63,0x65, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,0x52, 0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x12, 0x2f, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18,0x02, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x1b, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65,@@ -1207,118 +1160,116 @@ var file_v1_instance_service_proto_rawDesc = []byte{0x0a, 0x03, 0x73, 0x69, 0x64, 0x18, 0x0d, 0x20, 0x01, 0x28, 0x09, 0x52, 0x03, 0x73, 0x69, 0x64,0x12, 0x21, 0x0a, 0x0c, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x5f, 0x6e, 0x61, 0x6d, 0x65,0x18, 0x0e, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x73, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x4e,- 0x61, 0x6d, 0x65, 0x12, 0x35, 0x0a, 0x0a, 0x73, 0x73, 0x68, 0x5f, 0x63, 0x6f, 0x6e, 0x66, 0x69,- 0x67, 0x18, 0x0f, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x16, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61,- 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x53, 0x48, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x52,- 0x09, 0x73, 0x73, 0x68, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x22, 0x84, 0x01, 0x0a, 0x09, 0x53,- 0x53, 0x48, 0x43, 0x6f, 0x6e, 0x66, 0x69, 0x67, 0x12, 0x12, 0x0a, 0x04, 0x68, 0x6f, 0x73, 0x74,- 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x68, 0x6f, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04,- 0x70, 0x6f, 0x72, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x70, 0x6f, 0x72, 0x74,- 0x12, 0x12, 0x0a, 0x04, 0x75, 0x73, 0x65, 0x72, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04,- 0x75, 0x73, 0x65, 0x72, 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64,- 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64,- 0x12, 0x1f, 0x0a, 0x0b, 0x70, 0x72, 0x69, 0x76, 0x61, 0x74, 0x65, 0x5f, 0x6b, 0x65, 0x79, 0x18,- 0x05, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, 0x72, 0x69, 0x76, 0x61, 0x74, 0x65, 0x4b, 0x65,- 0x79, 0x2a, 0x47, 0x0a, 0x0e, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x54,- 0x79, 0x70, 0x65, 0x12, 0x1b, 0x0a, 0x17, 0x44, 0x41, 0x54, 0x41, 0x5f, 0x53, 0x4f, 0x55, 0x52,- 0x43, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00,- 0x12, 0x09, 0x0a, 0x05, 0x41, 0x44, 0x4d, 0x49, 0x4e, 0x10, 0x01, 0x12, 0x0d, 0x0a, 0x09, 0x52,- 0x45, 0x41, 0x44, 0x5f, 0x4f, 0x4e, 0x4c, 0x59, 0x10, 0x02, 0x32, 0xca, 0x0b, 0x0a, 0x0f, 0x49,- 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x7b,- 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x1f, 0x2e,- 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x49,- 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15,- 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x6e, 0x73,- 0x74, 0x61, 0x6e, 0x63, 0x65, 0x22, 0x34, 0xda, 0x41, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x82, 0xd3,- 0xe4, 0x93, 0x02, 0x27, 0x12, 0x25, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x3d,- 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x2a, 0x2f, 0x69,- 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x2a, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d,- 0x4c, 0x69, 0x73, 0x74, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x21, 0x2e,- 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74,- 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74,- 0x1a, 0x22, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c,- 0x69, 0x73, 0x74, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70,- 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x36, 0xda, 0x41, 0x06, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x82,- 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x12, 0x25, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x70, 0x61, 0x72, 0x65,- 0x6e, 0x74, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f,- 0x2a, 0x7d, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x96, 0x01, 0x0a,- 0x0e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12,- 0x22, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x72,- 0x65, 0x61, 0x74, 0x65, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75,- 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76,- 0x31, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x22, 0x49, 0xda, 0x41, 0x0f, 0x70,- 0x61, 0x72, 0x65, 0x6e, 0x74, 0x2c, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x82, 0xd3,- 0xe4, 0x93, 0x02, 0x31, 0x3a, 0x08, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x22, 0x25,- 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x3d, 0x65, 0x6e, 0x76, 0x69,- 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x2a, 0x7d, 0x2f, 0x69, 0x6e, 0x73, 0x74,- 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0xa4, 0x01, 0x0a, 0x0e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65,- 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x22, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62,- 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x49, 0x6e, 0x73,- 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x62,- 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61,- 0x6e, 0x63, 0x65, 0x22, 0x57, 0xda, 0x41, 0x14, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65,- 0x2c, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x5f, 0x6d, 0x61, 0x73, 0x6b, 0x82, 0xd3, 0xe4, 0x93,- 0x02, 0x3a, 0x3a, 0x08, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x32, 0x2e, 0x2f, 0x76,- 0x31, 0x2f, 0x7b, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x2e, 0x6e, 0x61, 0x6d, 0x65,- 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x2a, 0x2f,- 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x2a, 0x7d, 0x12, 0x82, 0x01, 0x0a,- 0x0e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12,- 0x22, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65,- 0x6c, 0x65, 0x74, 0x65, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75,- 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f,- 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x34, 0xda, 0x41, 0x04,- 0x6e, 0x61, 0x6d, 0x65, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x2a, 0x25, 0x2f, 0x76, 0x31, 0x2f,- 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e,- 0x74, 0x73, 0x2f, 0x2a, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x2a,- 0x7d, 0x12, 0x8a, 0x01, 0x0a, 0x10, 0x55, 0x6e, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x49, 0x6e,- 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x24, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73,- 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x6e, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x49, 0x6e, 0x73,- 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x62,- 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61,- 0x6e, 0x63, 0x65, 0x22, 0x39, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x33, 0x3a, 0x01, 0x2a, 0x22, 0x2e,- 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f,- 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x2a, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63,- 0x65, 0x73, 0x2f, 0x2a, 0x7d, 0x3a, 0x75, 0x6e, 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x12, 0x8d,- 0x01, 0x0a, 0x0d, 0x41, 0x64, 0x64, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65,- 0x12, 0x21, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41,- 0x64, 0x64, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75,- 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76,- 0x31, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x22, 0x42, 0x82, 0xd3, 0xe4, 0x93,- 0x02, 0x3c, 0x3a, 0x01, 0x2a, 0x22, 0x37, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x69, 0x6e, 0x73, 0x74,- 0x61, 0x6e, 0x63, 0x65, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74,- 0x73, 0x2f, 0x2a, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x2a, 0x7d,- 0x3a, 0x61, 0x64, 0x64, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12, 0x96,- 0x01, 0x0a, 0x10, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75,- 0x72, 0x63, 0x65, 0x12, 0x24, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76,- 0x31, 0x2e, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72,- 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x62, 0x79, 0x74, 0x65,- 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65,- 0x22, 0x45, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x3f, 0x3a, 0x01, 0x2a, 0x22, 0x3a, 0x2f, 0x76, 0x31,- 0x2f, 0x7b, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72,- 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x2a, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e,- 0x63, 0x65, 0x73, 0x2f, 0x2a, 0x7d, 0x3a, 0x72, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x44, 0x61, 0x74,- 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12, 0x96, 0x01, 0x0a, 0x10, 0x55, 0x70, 0x64, 0x61,- 0x74, 0x65, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12, 0x24, 0x2e, 0x62,- 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74,- 0x65, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65,- 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31,- 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x22, 0x45, 0x82, 0xd3, 0xe4, 0x93, 0x02,- 0x3f, 0x3a, 0x01, 0x2a, 0x32, 0x3a, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x69, 0x6e, 0x73, 0x74, 0x61,- 0x6e, 0x63, 0x65, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73,- 0x2f, 0x2a, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x2a, 0x7d, 0x3a,- 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65,- 0x12, 0x94, 0x01, 0x0a, 0x0f, 0x53, 0x79, 0x6e, 0x63, 0x53, 0x6c, 0x6f, 0x77, 0x51, 0x75, 0x65,- 0x72, 0x69, 0x65, 0x73, 0x12, 0x23, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e,- 0x76, 0x31, 0x2e, 0x53, 0x79, 0x6e, 0x63, 0x53, 0x6c, 0x6f, 0x77, 0x51, 0x75, 0x65, 0x72, 0x69,- 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67,- 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74,- 0x79, 0x22, 0x44, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x3e, 0x3a, 0x01, 0x2a, 0x22, 0x39, 0x2f, 0x76,+ 0x61, 0x6d, 0x65, 0x12, 0x19, 0x0a, 0x08, 0x73, 0x73, 0x68, 0x5f, 0x68, 0x6f, 0x73, 0x74, 0x18,+ 0x0f, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x73, 0x68, 0x48, 0x6f, 0x73, 0x74, 0x12, 0x19,+ 0x0a, 0x08, 0x73, 0x73, 0x68, 0x5f, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x10, 0x20, 0x01, 0x28, 0x09,+ 0x52, 0x07, 0x73, 0x73, 0x68, 0x50, 0x6f, 0x72, 0x74, 0x12, 0x19, 0x0a, 0x08, 0x73, 0x73, 0x68,+ 0x5f, 0x75, 0x73, 0x65, 0x72, 0x18, 0x11, 0x20, 0x01, 0x28, 0x09, 0x52, 0x07, 0x73, 0x73, 0x68,+ 0x55, 0x73, 0x65, 0x72, 0x12, 0x26, 0x0a, 0x0c, 0x73, 0x73, 0x68, 0x5f, 0x70, 0x61, 0x73, 0x73,+ 0x77, 0x6f, 0x72, 0x64, 0x18, 0x12, 0x20, 0x01, 0x28, 0x09, 0x42, 0x03, 0xe0, 0x41, 0x04, 0x52,+ 0x0b, 0x73, 0x73, 0x68, 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x12, 0x2b, 0x0a, 0x0f,+ 0x73, 0x73, 0x68, 0x5f, 0x70, 0x72, 0x69, 0x76, 0x61, 0x74, 0x65, 0x5f, 0x6b, 0x65, 0x79, 0x18,+ 0x13, 0x20, 0x01, 0x28, 0x09, 0x42, 0x03, 0xe0, 0x41, 0x04, 0x52, 0x0d, 0x73, 0x73, 0x68, 0x50,+ 0x72, 0x69, 0x76, 0x61, 0x74, 0x65, 0x4b, 0x65, 0x79, 0x2a, 0x47, 0x0a, 0x0e, 0x44, 0x61, 0x74,+ 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x54, 0x79, 0x70, 0x65, 0x12, 0x1b, 0x0a, 0x17, 0x44,+ 0x41, 0x54, 0x41, 0x5f, 0x53, 0x4f, 0x55, 0x52, 0x43, 0x45, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45,+ 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x09, 0x0a, 0x05, 0x41, 0x44, 0x4d, 0x49,+ 0x4e, 0x10, 0x01, 0x12, 0x0d, 0x0a, 0x09, 0x52, 0x45, 0x41, 0x44, 0x5f, 0x4f, 0x4e, 0x4c, 0x59,+ 0x10, 0x02, 0x32, 0xca, 0x0b, 0x0a, 0x0f, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x53,+ 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x7b, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x73,+ 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x1f, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65,+ 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52,+ 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73,+ 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x22, 0x34, 0xda,+ 0x41, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x12, 0x25, 0x2f, 0x76,+ 0x31, 0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d,+ 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x2a, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73,+ 0x2f, 0x2a, 0x7d, 0x12, 0x8e, 0x01, 0x0a, 0x0d, 0x4c, 0x69, 0x73, 0x74, 0x49, 0x6e, 0x73, 0x74,+ 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0x21, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65,+ 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65,+ 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62,+ 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x49, 0x6e, 0x73, 0x74, 0x61,+ 0x6e, 0x63, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x36, 0xda, 0x41,+ 0x06, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x27, 0x12, 0x25, 0x2f,+ 0x76, 0x31, 0x2f, 0x7b, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72,+ 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x2a, 0x7d, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61,+ 0x6e, 0x63, 0x65, 0x73, 0x12, 0x96, 0x01, 0x0a, 0x0e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x49,+ 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x22, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61,+ 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x49, 0x6e, 0x73, 0x74,+ 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x62, 0x79,+ 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e,+ 0x63, 0x65, 0x22, 0x49, 0xda, 0x41, 0x0f, 0x70, 0x61, 0x72, 0x65, 0x6e, 0x74, 0x2c, 0x69, 0x6e,+ 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x31, 0x3a, 0x08, 0x69, 0x6e,+ 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x22, 0x25, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x70, 0x61, 0x72,+ 0x65, 0x6e, 0x74, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73,+ 0x2f, 0x2a, 0x7d, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x12, 0xa4, 0x01,+ 0x0a, 0x0e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65,+ 0x12, 0x22, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55,+ 0x70, 0x64, 0x61, 0x74, 0x65, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71,+ 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e,+ 0x76, 0x31, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x22, 0x57, 0xda, 0x41, 0x14,+ 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x2c, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x5f,+ 0x6d, 0x61, 0x73, 0x6b, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x3a, 0x3a, 0x08, 0x69, 0x6e, 0x73, 0x74,+ 0x61, 0x6e, 0x63, 0x65, 0x32, 0x2e, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x69, 0x6e, 0x73, 0x74, 0x61,+ 0x6e, 0x63, 0x65, 0x2e, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f, 0x6e,+ 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x2a, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65,+ 0x73, 0x2f, 0x2a, 0x7d, 0x12, 0x82, 0x01, 0x0a, 0x0e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x49,+ 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x22, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61,+ 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x49, 0x6e, 0x73, 0x74,+ 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f,+ 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d,+ 0x70, 0x74, 0x79, 0x22, 0x34, 0xda, 0x41, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x82, 0xd3, 0xe4, 0x93,+ 0x02, 0x27, 0x2a, 0x25, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x6e, 0x61, 0x6d, 0x65, 0x3d, 0x65, 0x6e,+ 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x2a, 0x2f, 0x69, 0x6e, 0x73,+ 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x2a, 0x7d, 0x12, 0x8a, 0x01, 0x0a, 0x10, 0x55, 0x6e,+ 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x12, 0x24,+ 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x6e, 0x64,+ 0x65, 0x6c, 0x65, 0x74, 0x65, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x52, 0x65, 0x71,+ 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e,+ 0x76, 0x31, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x22, 0x39, 0x82, 0xd3, 0xe4,+ 0x93, 0x02, 0x33, 0x3a, 0x01, 0x2a, 0x22, 0x2e, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x6e, 0x61, 0x6d,+ 0x65, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x2a,+ 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x2a, 0x7d, 0x3a, 0x75, 0x6e,+ 0x64, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x12, 0x8d, 0x01, 0x0a, 0x0d, 0x41, 0x64, 0x64, 0x44, 0x61,+ 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12, 0x21, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62,+ 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x41, 0x64, 0x64, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f,+ 0x75, 0x72, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x62, 0x79,+ 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e,+ 0x63, 0x65, 0x22, 0x42, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x3c, 0x3a, 0x01, 0x2a, 0x22, 0x37, 0x2f,+ 0x76, 0x31, 0x2f, 0x7b, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x3d, 0x65, 0x6e, 0x76,+ 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x2a, 0x2f, 0x69, 0x6e, 0x73, 0x74,+ 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x2a, 0x7d, 0x3a, 0x61, 0x64, 0x64, 0x44, 0x61, 0x74, 0x61,+ 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12, 0x96, 0x01, 0x0a, 0x10, 0x52, 0x65, 0x6d, 0x6f, 0x76,+ 0x65, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12, 0x24, 0x2e, 0x62, 0x79,+ 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65,+ 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,+ 0x74, 0x1a, 0x15, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e,+ 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x22, 0x45, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x3f,+ 0x3a, 0x01, 0x2a, 0x22, 0x3a, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e,+ 0x63, 0x65, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f,+ 0x2a, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x2a, 0x7d, 0x3a, 0x72,+ 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12,+ 0x96, 0x01, 0x0a, 0x10, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f,+ 0x75, 0x72, 0x63, 0x65, 0x12, 0x24, 0x2e, 0x62, 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e,+ 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x44, 0x61, 0x74, 0x61, 0x53, 0x6f, 0x75,+ 0x72, 0x63, 0x65, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x15, 0x2e, 0x62, 0x79, 0x74,+ 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x49, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63,+ 0x65, 0x22, 0x45, 0x82, 0xd3, 0xe4, 0x93, 0x02, 0x3f, 0x3a, 0x01, 0x2a, 0x32, 0x3a, 0x2f, 0x76,0x31, 0x2f, 0x7b, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x3d, 0x65, 0x6e, 0x76, 0x69,0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x2f, 0x2a, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61,- 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x2a, 0x7d, 0x3a, 0x73, 0x79, 0x6e, 0x63, 0x53, 0x6c, 0x6f, 0x77,- 0x51, 0x75, 0x65, 0x72, 0x69, 0x65, 0x73, 0x42, 0x11, 0x5a, 0x0f, 0x67, 0x65, 0x6e, 0x65, 0x72,- 0x61, 0x74, 0x65, 0x64, 0x2d, 0x67, 0x6f, 0x2f, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74,- 0x6f, 0x33,+ 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x2a, 0x7d, 0x3a, 0x75, 0x70, 0x64, 0x61, 0x74, 0x65, 0x44, 0x61,+ 0x74, 0x61, 0x53, 0x6f, 0x75, 0x72, 0x63, 0x65, 0x12, 0x94, 0x01, 0x0a, 0x0f, 0x53, 0x79, 0x6e,+ 0x63, 0x53, 0x6c, 0x6f, 0x77, 0x51, 0x75, 0x65, 0x72, 0x69, 0x65, 0x73, 0x12, 0x23, 0x2e, 0x62,+ 0x79, 0x74, 0x65, 0x62, 0x61, 0x73, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x79, 0x6e, 0x63, 0x53,+ 0x6c, 0x6f, 0x77, 0x51, 0x75, 0x65, 0x72, 0x69, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73,+ 0x74, 0x1a, 0x16, 0x2e, 0x67, 0x6f, 0x6f, 0x67, 0x6c, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,+ 0x62, 0x75, 0x66, 0x2e, 0x45, 0x6d, 0x70, 0x74, 0x79, 0x22, 0x44, 0x82, 0xd3, 0xe4, 0x93, 0x02,+ 0x3e, 0x3a, 0x01, 0x2a, 0x22, 0x39, 0x2f, 0x76, 0x31, 0x2f, 0x7b, 0x69, 0x6e, 0x73, 0x74, 0x61,+ 0x6e, 0x63, 0x65, 0x3d, 0x65, 0x6e, 0x76, 0x69, 0x72, 0x6f, 0x6e, 0x6d, 0x65, 0x6e, 0x74, 0x73,+ 0x2f, 0x2a, 0x2f, 0x69, 0x6e, 0x73, 0x74, 0x61, 0x6e, 0x63, 0x65, 0x73, 0x2f, 0x2a, 0x7d, 0x3a,+ 0x73, 0x79, 0x6e, 0x63, 0x53, 0x6c, 0x6f, 0x77, 0x51, 0x75, 0x65, 0x72, 0x69, 0x65, 0x73, 0x42,+ 0x11, 0x5a, 0x0f, 0x67, 0x65, 0x6e, 0x65, 0x72, 0x61, 0x74, 0x65, 0x64, 0x2d, 0x67, 0x6f, 0x2f,+ 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,}var (@@ -1334,7 +1285,7 @@ func file_v1_instance_service_proto_rawDescGZIP() []byte {}var file_v1_instance_service_proto_enumTypes = make([]protoimpl.EnumInfo, 1)-var file_v1_instance_service_proto_msgTypes = make([]protoimpl.MessageInfo, 14)+var file_v1_instance_service_proto_msgTypes = make([]protoimpl.MessageInfo, 13)var file_v1_instance_service_proto_goTypes = []interface{}{(DataSourceType)(0), // 0: bytebase.v1.DataSourceType(*GetInstanceRequest)(nil), // 1: bytebase.v1.GetInstanceRequest@@ -1350,51 +1301,49 @@ var file_v1_instance_service_proto_goTypes = []interface{}{(*SyncSlowQueriesRequest)(nil), // 11: bytebase.v1.SyncSlowQueriesRequest(*Instance)(nil), // 12: bytebase.v1.Instance(*DataSource)(nil), // 13: bytebase.v1.DataSource- (*SSHConfig)(nil), // 14: bytebase.v1.SSHConfig- (*fieldmaskpb.FieldMask)(nil), // 15: google.protobuf.FieldMask- (State)(0), // 16: bytebase.v1.State- (Engine)(0), // 17: bytebase.v1.Engine- (*emptypb.Empty)(nil), // 18: google.protobuf.Empty+ (*fieldmaskpb.FieldMask)(nil), // 14: google.protobuf.FieldMask+ (State)(0), // 15: bytebase.v1.State+ (Engine)(0), // 16: bytebase.v1.Engine+ (*emptypb.Empty)(nil), // 17: google.protobuf.Empty}var file_v1_instance_service_proto_depIdxs = []int32{12, // 0: bytebase.v1.ListInstancesResponse.instances:type_name -> bytebase.v1.Instance12, // 1: bytebase.v1.CreateInstanceRequest.instance:type_name -> bytebase.v1.Instance12, // 2: bytebase.v1.UpdateInstanceRequest.instance:type_name -> bytebase.v1.Instance- 15, // 3: bytebase.v1.UpdateInstanceRequest.update_mask:type_name -> google.protobuf.FieldMask+ 14, // 3: bytebase.v1.UpdateInstanceRequest.update_mask:type_name -> google.protobuf.FieldMask13, // 4: bytebase.v1.AddDataSourceRequest.data_sources:type_name -> bytebase.v1.DataSource13, // 5: bytebase.v1.RemoveDataSourceRequest.data_sources:type_name -> bytebase.v1.DataSource13, // 6: bytebase.v1.UpdateDataSourceRequest.data_sources:type_name -> bytebase.v1.DataSource- 15, // 7: bytebase.v1.UpdateDataSourceRequest.update_mask:type_name -> google.protobuf.FieldMask- 16, // 8: bytebase.v1.Instance.state:type_name -> bytebase.v1.State- 17, // 9: bytebase.v1.Instance.engine:type_name -> bytebase.v1.Engine+ 14, // 7: bytebase.v1.UpdateDataSourceRequest.update_mask:type_name -> google.protobuf.FieldMask+ 15, // 8: bytebase.v1.Instance.state:type_name -> bytebase.v1.State+ 16, // 9: bytebase.v1.Instance.engine:type_name -> bytebase.v1.Engine13, // 10: bytebase.v1.Instance.data_sources:type_name -> bytebase.v1.DataSource0, // 11: bytebase.v1.DataSource.type:type_name -> bytebase.v1.DataSourceType- 14, // 12: bytebase.v1.DataSource.ssh_config:type_name -> bytebase.v1.SSHConfig- 1, // 13: bytebase.v1.InstanceService.GetInstance:input_type -> bytebase.v1.GetInstanceRequest- 2, // 14: bytebase.v1.InstanceService.ListInstances:input_type -> bytebase.v1.ListInstancesRequest- 4, // 15: bytebase.v1.InstanceService.CreateInstance:input_type -> bytebase.v1.CreateInstanceRequest- 5, // 16: bytebase.v1.InstanceService.UpdateInstance:input_type -> bytebase.v1.UpdateInstanceRequest- 6, // 17: bytebase.v1.InstanceService.DeleteInstance:input_type -> bytebase.v1.DeleteInstanceRequest- 7, // 18: bytebase.v1.InstanceService.UndeleteInstance:input_type -> bytebase.v1.UndeleteInstanceRequest- 8, // 19: bytebase.v1.InstanceService.AddDataSource:input_type -> bytebase.v1.AddDataSourceRequest- 9, // 20: bytebase.v1.InstanceService.RemoveDataSource:input_type -> bytebase.v1.RemoveDataSourceRequest- 10, // 21: bytebase.v1.InstanceService.UpdateDataSource:input_type -> bytebase.v1.UpdateDataSourceRequest- 11, // 22: bytebase.v1.InstanceService.SyncSlowQueries:input_type -> bytebase.v1.SyncSlowQueriesRequest- 12, // 23: bytebase.v1.InstanceService.GetInstance:output_type -> bytebase.v1.Instance- 3, // 24: bytebase.v1.InstanceService.ListInstances:output_type -> bytebase.v1.ListInstancesResponse- 12, // 25: bytebase.v1.InstanceService.CreateInstance:output_type -> bytebase.v1.Instance- 12, // 26: bytebase.v1.InstanceService.UpdateInstance:output_type -> bytebase.v1.Instance- 18, // 27: bytebase.v1.InstanceService.DeleteInstance:output_type -> google.protobuf.Empty- 12, // 28: bytebase.v1.InstanceService.UndeleteInstance:output_type -> bytebase.v1.Instance- 12, // 29: bytebase.v1.InstanceService.AddDataSource:output_type -> bytebase.v1.Instance- 12, // 30: bytebase.v1.InstanceService.RemoveDataSource:output_type -> bytebase.v1.Instance- 12, // 31: bytebase.v1.InstanceService.UpdateDataSource:output_type -> bytebase.v1.Instance- 18, // 32: bytebase.v1.InstanceService.SyncSlowQueries:output_type -> google.protobuf.Empty- 23, // [23:33] is the sub-list for method output_type- 13, // [13:23] is the sub-list for method input_type- 13, // [13:13] is the sub-list for extension type_name- 13, // [13:13] is the sub-list for extension extendee- 0, // [0:13] is the sub-list for field type_name+ 1, // 12: bytebase.v1.InstanceService.GetInstance:input_type -> bytebase.v1.GetInstanceRequest+ 2, // 13: bytebase.v1.InstanceService.ListInstances:input_type -> bytebase.v1.ListInstancesRequest+ 4, // 14: bytebase.v1.InstanceService.CreateInstance:input_type -> bytebase.v1.CreateInstanceRequest+ 5, // 15: bytebase.v1.InstanceService.UpdateInstance:input_type -> bytebase.v1.UpdateInstanceRequest+ 6, // 16: bytebase.v1.InstanceService.DeleteInstance:input_type -> bytebase.v1.DeleteInstanceRequest+ 7, // 17: bytebase.v1.InstanceService.UndeleteInstance:input_type -> bytebase.v1.UndeleteInstanceRequest+ 8, // 18: bytebase.v1.InstanceService.AddDataSource:input_type -> bytebase.v1.AddDataSourceRequest+ 9, // 19: bytebase.v1.InstanceService.RemoveDataSource:input_type -> bytebase.v1.RemoveDataSourceRequest+ 10, // 20: bytebase.v1.InstanceService.UpdateDataSource:input_type -> bytebase.v1.UpdateDataSourceRequest+ 11, // 21: bytebase.v1.InstanceService.SyncSlowQueries:input_type -> bytebase.v1.SyncSlowQueriesRequest+ 12, // 22: bytebase.v1.InstanceService.GetInstance:output_type -> bytebase.v1.Instance+ 3, // 23: bytebase.v1.InstanceService.ListInstances:output_type -> bytebase.v1.ListInstancesResponse+ 12, // 24: bytebase.v1.InstanceService.CreateInstance:output_type -> bytebase.v1.Instance+ 12, // 25: bytebase.v1.InstanceService.UpdateInstance:output_type -> bytebase.v1.Instance+ 17, // 26: bytebase.v1.InstanceService.DeleteInstance:output_type -> google.protobuf.Empty+ 12, // 27: bytebase.v1.InstanceService.UndeleteInstance:output_type -> bytebase.v1.Instance+ 12, // 28: bytebase.v1.InstanceService.AddDataSource:output_type -> bytebase.v1.Instance+ 12, // 29: bytebase.v1.InstanceService.RemoveDataSource:output_type -> bytebase.v1.Instance+ 12, // 30: bytebase.v1.InstanceService.UpdateDataSource:output_type -> bytebase.v1.Instance+ 17, // 31: bytebase.v1.InstanceService.SyncSlowQueries:output_type -> google.protobuf.Empty+ 22, // [22:32] is the sub-list for method output_type+ 12, // [12:22] is the sub-list for method input_type+ 12, // [12:12] is the sub-list for extension type_name+ 12, // [12:12] is the sub-list for extension extendee+ 0, // [0:12] is the sub-list for field type_name}func init() { file_v1_instance_service_proto_init() }@@ -1560,18 +1509,6 @@ func file_v1_instance_service_proto_init() {return nil}}- file_v1_instance_service_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} {- switch v := v.(*SSHConfig); i {- case 0:- return &v.state- case 1:- return &v.sizeCache- case 2:- return &v.unknownFields- default:- return nil- }- }}type x struct{}out := protoimpl.TypeBuilder{@@ -1579,7 +1516,7 @@ func file_v1_instance_service_proto_init() {GoPackagePath: reflect.TypeOf(x{}).PkgPath(),RawDescriptor: file_v1_instance_service_proto_rawDesc,NumEnums: 1,- NumMessages: 14,+ NumMessages: 13,NumExtensions: 0,NumServices: 1,},diff --git a/proto/store/data_source.proto b/proto/store/data_source.protoindex 17fb9793b2..07acd0cccc 100644--- a/proto/store/data_source.proto+++ b/proto/store/data_source.proto@@ -14,17 +14,15 @@ message DataSourceOptions {// sid and service_name are used for Oracle.string sid = 3;string service_name = 4;-}--message SSHConfig {- // The hostname of the SSH server agent.- string host = 1;- // The port of the SSH server agent. It's 22 typically.- string port = 2;- // The user to login the server.- string user = 3;- // The password to login the server. If it's empty string, no password is required.- string password = 4;- // The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK").- string private_key = 5;-}+ // SSH related+ // The hostname of the SSH server agent.+ string ssh_host = 5;+ // The port of the SSH server agent. It's 22 typically.+ string ssh_port = 6;+ // The user to login the server.+ string ssh_user = 7;+ // The password to login the server. If it's empty string, no password is required.+ string ssh_obfuscated_password = 8;+ // The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK").+ string ssh_obfuscated_private_key = 9;+}\ No newline at end of filediff --git a/proto/v1/instance_service.proto b/proto/v1/instance_service.protoindex a02b18ed4f..58227b104d 100644--- a/proto/v1/instance_service.proto+++ b/proto/v1/instance_service.proto@@ -231,28 +231,23 @@ message DataSource {string sid = 13;string service_name = 14;// Connection over SSH.- SSHConfig ssh_config = 15;-}--enum DataSourceType {- DATA_SOURCE_UNSPECIFIED = 0;- ADMIN = 1;- READ_ONLY = 2;-}---message SSHConfig {// The hostname of the SSH server agent.// Required.- string host = 1;+ string ssh_host = 15;// The port of the SSH server agent. It's 22 typically.// Required.- string port = 2;+ string ssh_port = 16;// The user to login the server.// Required.- string user = 3;+ string ssh_user = 17;// The password to login the server. If it's empty string, no password is required.- string password = 4;+ string ssh_password = 18 [(google.api.field_behavior) = INPUT_ONLY];// The private key to login the server. If it's empty string, we will use the system default private key from os.Getenv("SSH_AUTH_SOCK").- string private_key = 5;+ string ssh_private_key = 19 [(google.api.field_behavior) = INPUT_ONLY];+}++enum DataSourceType {+ DATA_SOURCE_UNSPECIFIED = 0;+ ADMIN = 1;+ READ_ONLY = 2;}