serverUtils

package
v0.0.0-...-66d4e42 Latest Latest
Warning

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

Go to latest
Published: Apr 8, 2022 License: GPL-3.0 Imports: 32 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BakLog

func BakLog(src string)

func CheckoutCodes

func CheckoutCodes(build *serverModel.Build)

func Download

func Download(uri string, dst string) error

func DownloadCodes

func DownloadCodes(build *serverModel.Build)

func ErrRes

func ErrRes(msg string) serverModel.RespData

func GetGitProjectName

func GetGitProjectName(gitUrl string) string

func GetIp

func GetIp() (ipAddr string, macAddr string)

func GetSysInfo

func GetSysInfo() (info serverModel.SysInfo)

func GetTestScript

func GetTestScript(build *serverModel.Build) (result serverModel.OptResult)

func GetUserHome

func GetUserHome() (string, error)

func GetZipSingleDir

func GetZipSingleDir(path string) string

func IsHostAgent

func IsHostAgent() bool

func IsVmAgent

func IsVmAgent() bool

func ListHistoryLog

func ListHistoryLog() (ret []map[string]string)

func OutputErr

func OutputErr(err error, writer http.ResponseWriter)

func ParserGetParam

func ParserGetParam(values url.Values, name, short string) (val string)

func ParserGetParams

func ParserGetParams(req *http.Request) (method string, params map[string]string)

func ParserJsonReq

func ParserJsonReq(bytes []byte, obj *serverModel.ReqData) (err error)

func ParserPostParam

func ParserPostParam(req *http.Request, paramName1, paramName2 string, dft string, isFile bool) (ret string)

func SetupCORS

func SetupCORS(w *http.ResponseWriter, req *http.Request)

func WriteRes

func WriteRes(ret serverModel.RespData, writer http.ResponseWriter)

Types

This section is empty.

Jump to

Keyboard shortcuts

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