Documentation ¶
Index ¶
- Variables
- func GetConfigDir() (string, error)
- func GetWorkspaceLogsDir(configDir string) (string, error)
- func IsLogFileNotFound(err error) bool
- func Save(c Config) error
- type Config
- type FRPSConfig
- type ILocalContainerRegistry
- type LogFileConfig
- type NetworkKey
- type Server
- func (s *Server) FetchSamples() ([]sample.Sample, *http.Response, error)
- func (s *Server) GetBinaryPath(binaryName, binaryVersion string) (string, error)
- func (s *Server) GetLogFiles() ([]string, error)
- func (s *Server) GetLogReader(logFileQuery string) (io.Reader, error)
- func (s *Server) Initialize() error
- func (s *Server) Purge(ctx context.Context, force bool) []error
- func (s *Server) Start() error
- type ServerInstanceConfig
- type TailscaleServer
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrLogFileNotFound = errors.New("log file not found")
)
Functions ¶
func GetConfigDir ¶ added in v0.11.0
func GetWorkspaceLogsDir ¶ added in v0.11.0
func IsLogFileNotFound ¶ added in v0.47.0
Types ¶
type Config ¶ added in v0.11.0
type Config struct { ProvidersDir string `json:"providersDir" validate:"required"` RegistryUrl string `json:"registryUrl" validate:"required"` Id string `json:"id" validate:"required"` ServerDownloadUrl string `json:"serverDownloadUrl" validate:"required"` Frps *FRPSConfig `json:"frps,omitempty" validate:"optional"` ApiPort uint32 `json:"apiPort" validate:"required"` HeadscalePort uint32 `json:"headscalePort" validate:"required"` BinariesPath string `json:"binariesPath" validate:"required"` LogFile *LogFileConfig `json:"logFile" validate:"required"` DefaultProjectImage string `json:"defaultProjectImage" validate:"required"` DefaultProjectUser string `json:"defaultProjectUser" validate:"required"` BuilderImage string `json:"builderImage" validate:"required"` LocalBuilderRegistryPort uint32 `json:"localBuilderRegistryPort" validate:"required"` LocalBuilderRegistryImage string `json:"localBuilderRegistryImage" validate:"required"` BuilderRegistryServer string `json:"builderRegistryServer" validate:"required"` BuildImageNamespace string `json:"buildImageNamespace" validate:"optional"` SamplesIndexUrl string `json:"samplesIndexUrl" validate:"optional"` } // @name ServerConfig
type FRPSConfig ¶ added in v0.11.0
type ILocalContainerRegistry ¶ added in v0.17.0
type LogFileConfig ¶ added in v0.45.0
type LogFileConfig struct { Path string `json:"path" validate:"required"` MaxSize int `json:"maxSize" validate:"required"` MaxBackups int `json:"maxBackups" validate:"required"` MaxAge int `json:"maxAge" validate:"required"` LocalTime bool `json:"localTime" validate:"optional"` Compress bool `json:"compress" validate:"optional"` } // @name LogFileConfig
type NetworkKey ¶ added in v0.11.0
type NetworkKey struct { Key string `json:"key" validate:"required"` } // @name NetworkKey
type Server ¶ added in v0.11.0
type Server struct { Id string Version string TailscaleServer TailscaleServer ProviderTargetService providertargets.IProviderTargetService ContainerRegistryService containerregistries.IContainerRegistryService BuildService builds.IBuildService ProjectConfigService projectconfig.IProjectConfigService LocalContainerRegistry ILocalContainerRegistry WorkspaceService workspaces.IWorkspaceService ApiKeyService apikeys.IApiKeyService GitProviderService gitproviders.IGitProviderService ProviderManager manager.IProviderManager ProfileDataService profiledata.IProfileDataService TelemetryService telemetry.TelemetryService // contains filtered or unexported fields }
func GetInstance ¶ added in v0.11.0
func GetInstance(serverConfig *ServerInstanceConfig) *Server
func (*Server) FetchSamples ¶ added in v0.27.0
func (*Server) GetBinaryPath ¶ added in v0.11.0
Check if the requested binary is already downloaded, if not, download it
func (*Server) GetLogFiles ¶ added in v0.47.0
func (*Server) GetLogReader ¶ added in v0.11.0
func (*Server) Initialize ¶ added in v0.36.0
type ServerInstanceConfig ¶ added in v0.11.0
type ServerInstanceConfig struct { Config Config Version string TailscaleServer TailscaleServer ProviderTargetService providertargets.IProviderTargetService ContainerRegistryService containerregistries.IContainerRegistryService BuildService builds.IBuildService ProjectConfigService projectconfig.IProjectConfigService LocalContainerRegistry ILocalContainerRegistry WorkspaceService workspaces.IWorkspaceService ApiKeyService apikeys.IApiKeyService GitProviderService gitproviders.IGitProviderService ProviderManager manager.IProviderManager ProfileDataService profiledata.IProfileDataService TelemetryService telemetry.TelemetryService }
Source Files ¶
Click to show internal directories.
Click to hide internal directories.