handler

package
v1.5.13 Latest Latest
Warning

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

Go to latest
Published: Mar 7, 2024 License: AGPL-3.0 Imports: 41 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var LeftNavigate = &navigate.Item{
	Display: true,
	Name:    `网站管理`,
	Action:  `caddy`,
	Icon:    `sitemap`,
	Children: &navigate.List{
		{
			Display: false,
			Name:    `Caddy日志`,
			Action:  `log_show`,
		},
		{
			Display: true,
			Name:    `网站列表`,
			Action:  `vhost`,
		},
		{
			Display: true,
			Name:    `添加网站`,
			Action:  `vhost_add`,
			Icon:    `plus`,
		},
		{
			Display: false,
			Name:    `重启Caddy`,
			Action:  `restart`,
			Icon:    ``,
		},
		{
			Display: false,
			Name:    `停止Caddy`,
			Action:  `stop`,
			Icon:    ``,
		},
		{
			Display: false,
			Name:    `查看网站日志`,
			Action:  `vhost_log`,
		},
		{
			Display: false,
			Name:    `查看网站动态`,
			Action:  `log`,
		},
		{
			Display: false,
			Name:    `配置表单`,
			Action:  `addon_form`,
			Icon:    ``,
		},
		{
			Display: false,
			Name:    `修改网站`,
			Action:  `vhost_edit`,
			Icon:    ``,
		},
		{
			Display: false,
			Name:    `删除网站`,
			Action:  `vhost_delete`,
			Icon:    ``,
		},
		{
			Display: false,
			Name:    `管理网站文件`,
			Action:  `vhost_file`,
			Icon:    ``,
		},
		{
			Display: false,
			Name:    `生成Caddyfile`,
			Action:  `vhost_build`,
			Icon:    ``,
		},

		{
			Display: true,
			Name:    `分组管理`,
			Action:  `group`,
		},
		{
			Display: true,
			Name:    `添加分组`,
			Action:  `group_add`,
			Icon:    `plus`,
		},
		{
			Display: false,
			Name:    `修改分组`,
			Action:  `group_edit`,
			Icon:    ``,
		},
		{
			Display: false,
			Name:    `删除分组`,
			Action:  `group_delete`,
			Icon:    ``,
		},

		{
			Display: true,
			Name:    `引擎配置`,
			Action:  `server`,
		},
		{
			Display: false,
			Name:    `添加引擎配置`,
			Action:  `server_add`,
			Icon:    `plus`,
		},
		{
			Display: false,
			Name:    `修改引擎配置`,
			Action:  `server_edit`,
			Icon:    ``,
		},
		{
			Display: false,
			Name:    `删除引擎配置`,
			Action:  `server_delete`,
			Icon:    ``,
		},
		{
			Display: false,
			Name:    `更新HTTPS证书`,
			Action:  `server_renew_cert`,
			Icon:    ``,
		},
	},
}

Functions

func AddonForm

func AddonForm(ctx echo.Context) error

func AddonIndex

func AddonIndex(ctx echo.Context) error

func DeleteCaddyfileByID

func DeleteCaddyfileByID(ctx echo.Context, serverIdent string, id uint, serverM ...*dbschema.NgingVhostServer) error

func Editable

func Editable(fileName string) (string, bool)

func Group

func Group(ctx echo.Context) error

func GroupAdd

func GroupAdd(ctx echo.Context) error

func GroupDelete

func GroupDelete(ctx echo.Context) error

func GroupEdit

func GroupEdit(ctx echo.Context) error

func Log

func Log(ctx echo.Context) error

func LogShow

func LogShow(ctx echo.Context) error

func ParseTailLine

func ParseTailLine(line *tail.Line) (interface{}, error)

func Playable

func Playable(fileName string) (string, bool)

func RegisterRoute

func RegisterRoute(r *route.Collection)

func Restart

func Restart(ctx echo.Context) error

func ServerAdd added in v1.4.7

func ServerAdd(ctx echo.Context) error

func ServerDelete added in v1.4.7

func ServerDelete(ctx echo.Context) error

func ServerEdit added in v1.4.7

func ServerEdit(ctx echo.Context) error

func ServerIndex added in v1.4.7

func ServerIndex(ctx echo.Context) error

func ServerRenewCert added in v1.4.10

func ServerRenewCert(ctx echo.Context) error

func Stop

func Stop(ctx echo.Context) error

func ValidAddonName

func ValidAddonName(addon string) bool

func VhostAdd

func VhostAdd(ctx echo.Context) error

func VhostDelete

func VhostDelete(ctx echo.Context) error

func VhostEdit

func VhostEdit(ctx echo.Context) error

func VhostFile

func VhostFile(ctx echo.Context) error

func VhostIndex

func VhostIndex(ctx echo.Context) error

func VhostLog

func VhostLog(ctx echo.Context) error

func Vhostbuild

func Vhostbuild(ctx echo.Context) error

Types

type DomainData added in v1.4.7

type DomainData struct {
	ID    uint
	Email string
}

type RequestCertUpdate added in v1.4.7

type RequestCertUpdate struct {
	Domains []string
	Email   string
}

Jump to

Keyboard shortcuts

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