config

package
v0.0.0-...-5f66263 Latest Latest
Warning

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

Go to latest
Published: Apr 20, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppConfiguration

type AppConfiguration struct {
	// app configuration
	Appname    *string `json:"appname"`
	AppDomain  *string `json:"appdomain"`
	AppIP      *string `json:"appip"`
	AppPort    *string `json:"appport"`
	Production *string `json:"production"`
	Version    *string `json:"version"`

	// misc
	FileSep *string `json:"filesep"`

	// DB         *DbInfo   `json:"dbinfo"`
	PgList       *[]PgInfo `json:"pglist"`
	SelectedPgDB *string   `json:"selectedpgdb"`

	// path
	PathLog   *string `json:"pathlog"`
	PathTemp  *string `json:"pathtemp"`
	PathPdf   *string `json:"pathpdf"`
	PathXlsx  *string `json:"pathxlsx"`
	PathCsv   *string `json:"pathcsv"`
	PathGraph *string `json:"pathgraph"`

	PathCrawlLog   *string `json:"pathcrawllog"`
	PathCrawlError *string `json:"pathcrawlerror"`
	PathCrawlHref  *string `json:"pathcrawlhref"`
	PathCrawlPdf   *string `json:"pathcrawlpdf"`

	// authentication
	AesKey      *string `json:"aeskey"`
	CookieName  *string `json:"cookiename"`
	ServiceName *string `json:"servicename"`
	UserHeader  *string `json:"userheader"`
}

func NewConfiguration

func NewConfiguration(filename string) (config *AppConfiguration, err error)

func (*AppConfiguration) GetConfiguration

func (c *AppConfiguration) GetConfiguration() (config *AppConfiguration)

type Configuration

type Configuration interface {
	GetConfiguration() (config *AppConfiguration)
}

type PgInfo

type PgInfo struct {
	Host        *string `json:"host"` // server ip
	DbName      *string `json:"dbname"`
	Username    *string `json:"username"`
	Password    *string `json:"password"`
	Port        *string `json:"port"`
	SSLMode     *string `json:"sslmode"`
	PoolMaxConn *string `json:"poolmaxconn"`
}

Jump to

Keyboard shortcuts

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