controller

package
v1.1.2 Latest Latest
Warning

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

Go to latest
Published: Aug 18, 2022 License: MulanPSL-2.0 Imports: 30 Imported by: 0

Documentation

Index

Constants

View Source
const (
	InstallTypeDefault = iota + 1
	InstallTypeForce
	InstallTypeUpgrade
	InstallTypeReConfig
)

Variables

This section is empty.

Functions

func CleanNotice added in v1.0.2

func CleanNotice(c *gin.Context)

func MetaInfo

func MetaInfo(c *gin.Context)

func SaveMetaInfo added in v1.0.2

func SaveMetaInfo(c *gin.Context)

func V2rayEndpointDetail

func V2rayEndpointDetail(c *gin.Context)

func V2rayEndpointDownload

func V2rayEndpointDownload(c *gin.Context)

func V2rayEndpointList

func V2rayEndpointList(c *gin.Context)

func V2rayEndpointNew

func V2rayEndpointNew(c *gin.Context)

func V2rayEndpointRemove

func V2rayEndpointRemove(c *gin.Context)

func V2rayServerDeploy

func V2rayServerDeploy(c *gin.Context)

Types

type SaveMetaInfoForm added in v1.0.2

type SaveMetaInfoForm struct {
	Key   string `json:"key"`
	Value string `json:"value"`
}

type V2rayEndpointDetailQuery

type V2rayEndpointDetailQuery struct {
	Id uint `form:"id"`
}

type V2rayEndpointDownloadBody

type V2rayEndpointDownloadBody struct {
	Id uint `json:"id"`
}

type V2rayEndpointNewForm

type V2rayEndpointNewForm struct {
	Remark string `json:"remark"`

	Host    string `json:"host"`
	Port    int    `json:"port"`
	UserId  string `json:"user_id"`
	AlterId int    `json:"alter_id"`
	UseTls  bool   `json:"use_tls"`

	TransportType int `json:"transport_type"`
	Tcp           struct {
		Type    string `json:"type"`
		Request struct {
			Version string               `json:"version"`
			Method  string               `json:"method"`
			Path    string               `json:"path"`
			Headers []v2ray.ConfigHeader `json:"headers"`
		} `json:"request"`
		Response struct {
			Version string               `json:"version"`
			Status  string               `json:"status"`
			Reason  string               `json:"reason"`
			Headers []v2ray.ConfigHeader `json:"headers"`
		} `json:"response"`
	} `json:"tcp"`
	WebSocket struct {
		Path    string               `json:"path"`
		Headers []v2ray.ConfigHeader `json:"headers"`
	} `json:"web_socket"`
	Kcp struct {
		Type             string `json:"type"`
		Mtu              int    `json:"mtu"`
		Tti              int    `json:"tti"`
		UpLinkCapacity   int    `json:"uplink_capacity"`
		DownLinkCapacity int    `json:"downlink_capacity"`
		Congestion       bool   `json:"congestion"`
		ReadBufferSize   int    `json:"read_buffer_size"`
		WriteBufferSize  int    `json:"write_buffer_size"`
	} `json:"kcp"`
	Http2 struct {
		Host string `json:"host"`
		Path string `json:"path"`
	} `json:"http2"`
}

type V2rayEndpointRemoveBody

type V2rayEndpointRemoveBody struct {
	Id       uint   `json:"id"`
	Password string `json:"password"`
}

type V2rayServerDeployForm

type V2rayServerDeployForm struct {
	InstallType   int    `json:"install_type"`
	ManagementKey string `json:"management_key"`

	UseTls  bool   `json:"use_tls"`
	TlsHost string `json:"tls_host"`

	EnableWebService bool   `json:"enable_web_service"`
	WebServiceType   string `json:"web_service_type"`

	CloudreveConfig struct {
		EnableAria2        bool `json:"enable_aria2"`
		ResetAdminPassword bool `json:"reset_admin_password"`
	} `json:"cloudreve_config"`

	V2rayConfig v2ray.Config `json:"v2ray_config"`
}

Jump to

Keyboard shortcuts

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