Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct { Templates map[string]string `json:"templates,omitempty"` CmsConfig CmsConfig `json:"cmsConfig"` UpdateDotlanOnEvents []messagebroker.MatchEvent `json:"updateDotlanOnEvents"` UnwindiaPteroConfig `json:"pterodactyl"` }
type ConfigClient ¶
type ConfigClient interface { GetConfig() *Config GetGameServerTemplate(gameName string) (*GamerServerConfigTemplate, error) GetGameServerTemplateForMatch(info matchservice.MatchInfo) (*GamerServerConfigTemplate, error) }
func NewConfigClient ¶
func NewConfigClient() (ConfigClient, error)
func NewConfigFile ¶
func NewConfigFile(ctx context.Context, filename, templatesDirectory string) (ConfigClient, error)
type ConfigClientImpl ¶
type ConfigClientImpl struct {
// contains filtered or unexported fields
}
func (ConfigClientImpl) GetConfig ¶
func (c ConfigClientImpl) GetConfig() *Config
TODO: Implement client for config service
func (ConfigClientImpl) GetGameServerTemplate ¶ added in v0.0.6
func (c ConfigClientImpl) GetGameServerTemplate(gameName string) (*GamerServerConfigTemplate, error)
func (ConfigClientImpl) GetGameServerTemplateForMatch ¶ added in v0.0.6
func (c ConfigClientImpl) GetGameServerTemplateForMatch(info matchservice.MatchInfo) (*GamerServerConfigTemplate, error)
type ConfigFileImpl ¶
type ConfigFileImpl struct {
// contains filtered or unexported fields
}
func (*ConfigFileImpl) GetConfig ¶
func (c *ConfigFileImpl) GetConfig() *Config
func (*ConfigFileImpl) GetGameServerTemplate ¶ added in v0.0.6
func (c *ConfigFileImpl) GetGameServerTemplate(gameName string) (*GamerServerConfigTemplate, error)
func (*ConfigFileImpl) GetGameServerTemplateForMatch ¶ added in v0.0.6
func (c *ConfigFileImpl) GetGameServerTemplateForMatch(info matchservice.MatchInfo) (*GamerServerConfigTemplate, error)
type Duration ¶ added in v0.0.6
func (Duration) MarshalJSON ¶ added in v0.0.6
func (*Duration) UnmarshalJSON ¶ added in v0.0.6
type GamerServerConfigTemplate ¶ added in v0.0.6
type GamerServerConfigTemplate struct { UserId int `json:"userId"` LocationId int `json:"locationId"` NestId int `json:"nestId"` ServerNamePrefix string `json:"serverNamePrefix"` ServerNameGOTVPrefix string `json:"serverNameGOTVPrefix"` DefaultStartup string `json:"defaultStartup"` DefaultDockerImage string `json:"defaultDockerImage"` DefaultServerPassword string `json:"defaultServerPassword"` DefaultRconPassword string `json:"defaultRconPassword"` EggId int `json:"eggId"` Limits crocgodyl.Limits `json:"limits"` // Limits which will be set for new servers. ForceLimits bool `json:"forceLimits"` // if true, server which does not meet Limits settings will be deleted. If false, existing suspended servers will be reused, no matter of matching Limits Environment map[string]interface{} `json:"environment"` // Environment settings for a game. Can be values or matching properties of a gameserver match thingy object in go-template like format // TODO: set correct object description TvSlots int `json:"tvSlots"` TvPortOffset int `json:"tvPortOffset"` DeleteAfterDuration Duration `json:"deleteAfterDuration"` SteamApiTokenAppId int `json:"steamApiTokenAppId"` EnvironmentMapping map[string]string `json:"envMapping"` }
type UnwindiaPteroConfig ¶ added in v0.0.6
type UnwindiaPteroConfig struct {
Configs map[string]GamerServerConfigTemplate `json:"configs"` // configs is a map which contains the game name as key with belonging template
}
Click to show internal directories.
Click to hide internal directories.