api

package
v14.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 13, 2021 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ProjectInfoApiPath  = "/api/v4/internal/kubernetes/project_info"
	ProjectIdQueryParam = "id"
)
View Source
const (
	AgentConfigurationApiPath = "/api/v4/internal/kubernetes/agent_configuration"
)
View Source
const (
	AgentInfoApiPath = "/api/v4/internal/kubernetes/agent_info"
)
View Source
const (
	AllowedAgentsApiPath = "/api/v4/job/allowed_agents"
)
View Source
const (
	ModuleRequestApiPath = "/api/v4/internal/kubernetes/modules/"
)
View Source
const (
	UsagePingApiPath = "/api/v4/internal/kubernetes/usage_metrics"
)

Variables

View Source
var File_internal_gitlab_api_api_proto protoreflect.FileDescriptor

Functions

func GetAgentInfo

func GetAgentInfo(ctx context.Context, client gitlab.ClientInterface, agentToken api.AgentToken) (*api.AgentInfo, error)

func GetProjectInfo added in v14.1.1

func GetProjectInfo(ctx context.Context, client gitlab.ClientInterface, agentToken api.AgentToken, projectId string) (*api.ProjectInfo, error)

func MakeModuleRequest added in v14.1.1

func MakeModuleRequest(ctx context.Context, client gitlab.ClientInterface, agentToken api.AgentToken, moduleName, method, urlPath string, query url.Values, header http.Header, body io.Reader) (*http.Response, error)

func PostAgentConfiguration added in v14.3.0

func PostAgentConfiguration(ctx context.Context, client gitlab.ClientInterface, agentId int64, config *agentcfg.ConfigurationFile) error

func SendUsagePing added in v14.1.1

func SendUsagePing(ctx context.Context, client gitlab.ClientInterface, counters map[string]int64) error

Types

type AllowedAgent added in v14.1.1

type AllowedAgent struct {
	Id            int64          `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	ConfigProject *ConfigProject `protobuf:"bytes,2,opt,name=config_project,proto3" json:"config_project,omitempty"`
	Configuration *Configuration `protobuf:"bytes,3,opt,name=configuration,proto3" json:"configuration,omitempty"`
	// contains filtered or unexported fields
}

func (*AllowedAgent) Descriptor deprecated added in v14.3.0

func (*AllowedAgent) Descriptor() ([]byte, []int)

Deprecated: Use AllowedAgent.ProtoReflect.Descriptor instead.

func (*AllowedAgent) GetConfigProject added in v14.3.0

func (x *AllowedAgent) GetConfigProject() *ConfigProject

func (*AllowedAgent) GetConfiguration added in v14.3.0

func (x *AllowedAgent) GetConfiguration() *Configuration

func (*AllowedAgent) GetId added in v14.3.0

func (x *AllowedAgent) GetId() int64

func (*AllowedAgent) ProtoMessage added in v14.3.0

func (*AllowedAgent) ProtoMessage()

func (*AllowedAgent) ProtoReflect added in v14.3.0

func (x *AllowedAgent) ProtoReflect() protoreflect.Message

func (*AllowedAgent) Reset added in v14.3.0

func (x *AllowedAgent) Reset()

func (*AllowedAgent) String added in v14.3.0

func (x *AllowedAgent) String() string

type AllowedAgentsForJob added in v14.1.1

type AllowedAgentsForJob struct {
	AllowedAgents []*AllowedAgent `protobuf:"bytes,1,rep,name=allowed_agents,proto3" json:"allowed_agents,omitempty"`
	Job           *Job            `protobuf:"bytes,2,opt,name=job,proto3" json:"job,omitempty"`
	Pipeline      *Pipeline       `protobuf:"bytes,3,opt,name=pipeline,proto3" json:"pipeline,omitempty"`
	Project       *Project        `protobuf:"bytes,4,opt,name=project,proto3" json:"project,omitempty"`
	User          *User           `protobuf:"bytes,5,opt,name=user,proto3" json:"user,omitempty"`
	// contains filtered or unexported fields
}

func GetAllowedAgentsForJob added in v14.1.1

func GetAllowedAgentsForJob(ctx context.Context, client gitlab.ClientInterface, jobToken string) (*AllowedAgentsForJob, error)

func (*AllowedAgentsForJob) Descriptor deprecated added in v14.3.0

func (*AllowedAgentsForJob) Descriptor() ([]byte, []int)

Deprecated: Use AllowedAgentsForJob.ProtoReflect.Descriptor instead.

func (*AllowedAgentsForJob) GetAllowedAgents added in v14.3.0

func (x *AllowedAgentsForJob) GetAllowedAgents() []*AllowedAgent

func (*AllowedAgentsForJob) GetJob added in v14.3.0

func (x *AllowedAgentsForJob) GetJob() *Job

func (*AllowedAgentsForJob) GetPipeline added in v14.3.0

func (x *AllowedAgentsForJob) GetPipeline() *Pipeline

func (*AllowedAgentsForJob) GetProject added in v14.3.0

func (x *AllowedAgentsForJob) GetProject() *Project

func (*AllowedAgentsForJob) GetUser added in v14.3.0

func (x *AllowedAgentsForJob) GetUser() *User

func (*AllowedAgentsForJob) ProtoMessage added in v14.3.0

func (*AllowedAgentsForJob) ProtoMessage()

func (*AllowedAgentsForJob) ProtoReflect added in v14.3.0

func (x *AllowedAgentsForJob) ProtoReflect() protoreflect.Message

func (*AllowedAgentsForJob) Reset added in v14.3.0

func (x *AllowedAgentsForJob) Reset()

func (*AllowedAgentsForJob) String added in v14.3.0

func (x *AllowedAgentsForJob) String() string

type ConfigProject added in v14.1.1

type ConfigProject struct {
	Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*ConfigProject) Descriptor deprecated added in v14.3.0

func (*ConfigProject) Descriptor() ([]byte, []int)

Deprecated: Use ConfigProject.ProtoReflect.Descriptor instead.

func (*ConfigProject) GetId added in v14.3.0

func (x *ConfigProject) GetId() int64

func (*ConfigProject) ProtoMessage added in v14.3.0

func (*ConfigProject) ProtoMessage()

func (*ConfigProject) ProtoReflect added in v14.3.0

func (x *ConfigProject) ProtoReflect() protoreflect.Message

func (*ConfigProject) Reset added in v14.3.0

func (x *ConfigProject) Reset()

func (*ConfigProject) String added in v14.3.0

func (x *ConfigProject) String() string

type Configuration added in v14.3.0

type Configuration struct {
	DefaultNamespace string                 `protobuf:"bytes,1,opt,name=default_namespace,proto3" json:"default_namespace,omitempty"`
	AccessAs         *agentcfg.CiAccessAsCF `protobuf:"bytes,2,opt,name=access_as,proto3" json:"access_as,omitempty"`
	// contains filtered or unexported fields
}

func (*Configuration) Descriptor deprecated added in v14.3.0

func (*Configuration) Descriptor() ([]byte, []int)

Deprecated: Use Configuration.ProtoReflect.Descriptor instead.

func (*Configuration) GetAccessAs added in v14.3.0

func (x *Configuration) GetAccessAs() *agentcfg.CiAccessAsCF

func (*Configuration) GetDefaultNamespace added in v14.3.0

func (x *Configuration) GetDefaultNamespace() string

func (*Configuration) ProtoMessage added in v14.3.0

func (*Configuration) ProtoMessage()

func (*Configuration) ProtoReflect added in v14.3.0

func (x *Configuration) ProtoReflect() protoreflect.Message

func (*Configuration) Reset added in v14.3.0

func (x *Configuration) Reset()

func (*Configuration) String added in v14.3.0

func (x *Configuration) String() string

type Job added in v14.1.1

type Job struct {
	Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*Job) Descriptor deprecated added in v14.3.0

func (*Job) Descriptor() ([]byte, []int)

Deprecated: Use Job.ProtoReflect.Descriptor instead.

func (*Job) GetId added in v14.3.0

func (x *Job) GetId() int64

func (*Job) ProtoMessage added in v14.3.0

func (*Job) ProtoMessage()

func (*Job) ProtoReflect added in v14.3.0

func (x *Job) ProtoReflect() protoreflect.Message

func (*Job) Reset added in v14.3.0

func (x *Job) Reset()

func (*Job) String added in v14.3.0

func (x *Job) String() string

type Pipeline added in v14.1.1

type Pipeline struct {
	Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*Pipeline) Descriptor deprecated added in v14.3.0

func (*Pipeline) Descriptor() ([]byte, []int)

Deprecated: Use Pipeline.ProtoReflect.Descriptor instead.

func (*Pipeline) GetId added in v14.3.0

func (x *Pipeline) GetId() int64

func (*Pipeline) ProtoMessage added in v14.3.0

func (*Pipeline) ProtoMessage()

func (*Pipeline) ProtoReflect added in v14.3.0

func (x *Pipeline) ProtoReflect() protoreflect.Message

func (*Pipeline) Reset added in v14.3.0

func (x *Pipeline) Reset()

func (*Pipeline) String added in v14.3.0

func (x *Pipeline) String() string

type Project added in v14.1.1

type Project struct {
	Id int64 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	// contains filtered or unexported fields
}

func (*Project) Descriptor deprecated added in v14.3.0

func (*Project) Descriptor() ([]byte, []int)

Deprecated: Use Project.ProtoReflect.Descriptor instead.

func (*Project) GetId added in v14.3.0

func (x *Project) GetId() int64

func (*Project) ProtoMessage added in v14.3.0

func (*Project) ProtoMessage()

func (*Project) ProtoReflect added in v14.3.0

func (x *Project) ProtoReflect() protoreflect.Message

func (*Project) Reset added in v14.3.0

func (x *Project) Reset()

func (*Project) String added in v14.3.0

func (x *Project) String() string

type ProjectInfoResponse added in v14.1.1

type ProjectInfoResponse struct {
	ProjectId        int64                   `json:"project_id"`
	GitalyInfo       gitlab.GitalyInfo       `json:"gitaly_info"`
	GitalyRepository gitlab.GitalyRepository `json:"gitaly_repository"`
}

type User added in v14.1.1

type User struct {
	Id       int64  `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
	Username string `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"`
	// contains filtered or unexported fields
}

func (*User) Descriptor deprecated added in v14.3.0

func (*User) Descriptor() ([]byte, []int)

Deprecated: Use User.ProtoReflect.Descriptor instead.

func (*User) GetId added in v14.3.0

func (x *User) GetId() int64

func (*User) GetUsername added in v14.3.0

func (x *User) GetUsername() string

func (*User) ProtoMessage added in v14.3.0

func (*User) ProtoMessage()

func (*User) ProtoReflect added in v14.3.0

func (x *User) ProtoReflect() protoreflect.Message

func (*User) Reset added in v14.3.0

func (x *User) Reset()

func (*User) String added in v14.3.0

func (x *User) String() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL