conf

package
v1.5.0 Latest Latest
Warning

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

Go to latest
Published: Jan 6, 2022 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Overview

Package conf Dicehub 环境配置

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Debug

func Debug() bool

Debug 是否处于调试模式

func EventBoxAddr

func EventBoxAddr() string

EventBoxAddr 返回eventbox地址

func ExtensionMenu

func ExtensionMenu() map[string][]string

ExtensionMenu 服务扩展菜单配置

func GCSwitch

func GCSwitch() bool

GCSwitch release自动回收开关

func ListenAddr

func ListenAddr() string

ListenAddr 返回 ListenAddr 选项.

func Load

func Load()

Load 加载环境变量配置.

func MaxTimeReserved

func MaxTimeReserved() string

MaxTimeReserved 未使用的release保留最长时间

func MonitorAddr

func MonitorAddr() string

MonitorAddr monitor

func OpsAddr

func OpsAddr() string

OpsAddr 返回ops地址

func SiteUrl

func SiteUrl() string

Types

type Conf

type Conf struct {
	ListenAddr      string              `env:"LISTEN_ADDR" default:":10000"`
	MonitorAddr     string              `env:"MONITOR_ADDR" default:"monitor.default.svc.cluster.local:7096"`
	Debug           bool                `env:"DEBUG" default:"false"`
	OpsAddr         string              `env:"OPS_ADDR"`
	EventBoxAddr    string              `env:"EVENTBOX_ADDR"`
	GCSwitch        bool                `env:"RELEASE_GC_SWITCH" default:"true"`
	MaxTimeReserved string              `env:"RELEASE_MAX_TIME_RESERVED" default:"72"` // default: 72h
	ExtensionMenu   map[string][]string `env:"EXTENSION_MENU" default:"{}"`
	SiteUrl         string              `env:"SITE_URL"`
}

Conf DiceHub 环境变量配置项

Jump to

Keyboard shortcuts

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