server

package
v1.0.12 Latest Latest
Warning

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

Go to latest
Published: Oct 20, 2025 License: Apache-2.0 Imports: 34 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

func NewConfig

func NewConfig(configPath string) (*viper.Viper, error)

Types

type ExposeServer

type ExposeServer struct {
	UI http.Handler
	// contains filtered or unexported fields
}

func NewExposeServer

func NewExposeServer(opts *Options, logger *zap.Logger) *ExposeServer

func (*ExposeServer) Run

func (s *ExposeServer) Run() error

type HTTPServer

type HTTPServer struct {
	*http.Server
	// contains filtered or unexported fields
}

func NewHTTPServer

func NewHTTPServer(logger *zap.SugaredLogger) *HTTPServer

func (*HTTPServer) Close

func (h *HTTPServer) Close() error

func (*HTTPServer) Run

func (h *HTTPServer) Run(addr string, handler http.Handler) error

func (*HTTPServer) Wait

func (h *HTTPServer) Wait() error

type Options

type Options struct {
	Domain     string
	PrivateKey string
	PublicKey  string
	SSHAddr    string
	HTTPAddr   string
	Password   string
	Logger     *logger.Options
}

func NewOptions

func NewOptions(v *viper.Viper) (*Options, error)

type SSHServer

type SSHServer struct {
	// contains filtered or unexported fields
}

func NewSSHServer

func NewSSHServer(opts *Options, logger *zap.SugaredLogger) *SSHServer

NewSSHServer returns new instance of SSHServer.

func (*SSHServer) Close

func (s *SSHServer) Close() error

Close closes and stops the SSH server.

func (*SSHServer) Run

func (s *SSHServer) Run() error

Run starts the SSH server.

func (*SSHServer) Wait

func (s *SSHServer) Wait() error

Wait waits for server to be stopped

Jump to

Keyboard shortcuts

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