server

package
v0.0.0-...-c57eb44 Latest Latest
Warning

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

Go to latest
Published: Nov 23, 2021 License: BSD-3-Clause Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Validators    map[string]map[string]interface{} `yaml:"validators"`
	Configurators map[string]map[string]interface{} `yaml:"configurators"`
	Listen        string                            `yaml:"listen"`
	DataDir       string                            `yaml:"data_dir"`
	CPU           int                               `yaml:"cpu"`
	RAM           int                               `yaml:"ram"`
}

type Server

type Server struct {
	Scheduler *scheduler.Scheduler
	AuthKey   string
	Addr      string
}

Server struct containing config

func New

func New(addr, dataDir, authKey string, cpu, ram int) (*Server, error)

New initializes server instance

func (*Server) Run

func (s *Server) Run(ctx context.Context)

Run starts this server instance

Jump to

Keyboard shortcuts

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