Documentation
¶
Index ¶
Constants ¶
View Source
const ( SettingsDirectory = "/opt/factorio/settings" FactOpSettings = SettingsDirectory + "/factop-settings.json" ServerSettings = SettingsDirectory + "/server-settings.json" ServerAdminList = SettingsDirectory + "/server-adminlist.json" ServerBanList = SettingsDirectory + "/server-banlist.json" )
View Source
const CreateSaveOutput = SaveLocation + "/create-save.log"
View Source
const CurrentSoftMod = SaveLocation + "/softmod.zip"
View Source
const FactorioBinary = FactorioDirectory + "/bin/x64/factorio"
View Source
const FactorioDirectory = "/opt/factorio/current"
View Source
const NewLine = "\n"
View Source
const NewSave = SaveLocation + "/newSave.zip"
View Source
const RconStartupMarker = "Starting RCON interface at IP ADDR"
View Source
const SaveFile = SaveLocation + "/save.zip"
View Source
const SaveLocation = "/opt/factorio/saves"
Variables ¶
View Source
var IgnorePattern = regexp.MustCompile(`(\d{4}-\d{2}-\d{2} \d{2}:\d{2}:\d{2}) \[(\w+)] (.+)`)
Functions ¶
Types ¶
type Command ¶
type Command struct {
servicego.DefaultLogger
Factorio *Factorio
}
func (*Command) Execute ¶
func (c *Command) Execute(ctx context.Context, req *api.CommandPayload) (*api.CommandResult, error)
type ComponentTemplate ¶
type ComponentTemplate struct {
servicego.DefaultLogger
}
ComponentTemplate is a template for creating new components
func (*ComponentTemplate) Start ¶
func (c *ComponentTemplate) Start(s *Service) error
func (*ComponentTemplate) Stop ¶
func (c *ComponentTemplate) Stop() error
type Factorio ¶
type Nats ¶
type Nats struct {
servicego.DefaultLogger
// contains filtered or unexported fields
}
func (*Nats) PublishMsg ¶
type Rcon ¶
type Rcon struct {
servicego.DefaultLogger
Factorio *Factorio
// contains filtered or unexported fields
}
func (*Rcon) Execute ¶
func (r *Rcon) Execute(_ context.Context, req *api.RconCommand) (*api.RconResult, error)
type Service ¶
type Settings ¶
type Settings struct {
servicego.DefaultLogger
}
func (*Settings) ServerAdmins ¶
func (s *Settings) ServerAdmins(ctx context.Context, req *api.ServerAdminsType) (*api.ServerAdminsType, error)
type SoftMod ¶
type SoftMod struct {
servicego.DefaultLogger
Factorio *Factorio
Service *Service
}
func (*SoftMod) ApplySoftMod ¶
Click to show internal directories.
Click to hide internal directories.