nginx

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Oct 23, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Module = fx.Module(
	"nginx",
	fx.Provide(New),
)

Functions

This section is empty.

Types

type Config

type Config struct {
	ConfigPath     string
	ConfigTemplate string
}

type Context

type Context struct {
	DomainName   string
	UpstreamName string
	Servers      []UpstreamServer
}

type Nginx

type Nginx struct {
	Config Config
	// contains filtered or unexported fields
}

func New

func New(cfg Config) *Nginx

func (*Nginx) Apply

func (n *Nginx) Apply(c Context) error

func (*Nginx) Remove

func (n *Nginx) Remove(hostname string) error

func (*Nginx) Render

func (n *Nginx) Render(c Context, w io.Writer) error

type UpstreamServer

type UpstreamServer struct {
	Host    string
	Port    uint16
	Options string
}

Jump to

Keyboard shortcuts

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