BIRDLG_BGPMAP_INFO 選項 (#44)
* BIRDLG_BGPMAP_INFO update the paramater description fix for bgpmap_test singleline and multiline * Static file instead of jsdelivr; favicon.ico Co-authored-by: testscript <testscript@example.com>
This commit is contained in:
@@ -21,6 +21,7 @@ type settingType struct {
|
||||
navBarBrandURL string
|
||||
navBarAllServer string
|
||||
navBarAllURL string
|
||||
bgpmapInfo string
|
||||
telegramBotName string
|
||||
protocolFilter []string
|
||||
}
|
||||
@@ -39,6 +40,7 @@ func main() {
|
||||
navBarBrandURL: "/",
|
||||
navBarAllServer: "All Servers",
|
||||
navBarAllURL: "all",
|
||||
bgpmapInfo: "asn,as-name,ASName,descr",
|
||||
telegramBotName: "",
|
||||
protocolFilter: []string{},
|
||||
}
|
||||
@@ -83,6 +85,9 @@ func main() {
|
||||
if env := os.Getenv("BIRDLG_NAVBAR_ALL_URL"); env != "" {
|
||||
settingDefault.navBarAllURL = env
|
||||
}
|
||||
if env := os.Getenv("BIRDLG_BGPMAP_INFO"); env != "" {
|
||||
settingDefault.bgpmapInfo = env
|
||||
}
|
||||
if env := os.Getenv("BIRDLG_TELEGRAM_BOT_NAME"); env != "" {
|
||||
settingDefault.telegramBotName = env
|
||||
}
|
||||
@@ -99,9 +104,10 @@ func main() {
|
||||
netSpecificModePtr := flag.String("net-specific-mode", settingDefault.netSpecificMode, "network specific operation mode, [(none)|dn42]")
|
||||
titleBrandPtr := flag.String("title-brand", settingDefault.titleBrand, "prefix of page titles in browser tabs")
|
||||
navBarBrandPtr := flag.String("navbar-brand", settingDefault.navBarBrand, "brand to show in the navigation bar")
|
||||
navBarBrandURLPtr := flag.String("navbar-brand-url", settingDefault.navBarBrandURL, "brand to show in the navigation bar")
|
||||
navBarAllServerPtr := flag.String("navbar-all-servers", settingDefault.navBarAllServer, "brand to show in the navigation bar")
|
||||
navBarAllURL := flag.String("navbar-all-url", settingDefault.navBarAllURL, "brand to show in the navigation bar")
|
||||
navBarBrandURLPtr := flag.String("navbar-brand-url", settingDefault.navBarBrandURL, "the url of the brand to show in the navigation bar")
|
||||
navBarAllServerPtr := flag.String("navbar-all-servers", settingDefault.navBarAllServer, "the text of \"All servers\" button in the navigation bar")
|
||||
navBarAllURL := flag.String("navbar-all-url", settingDefault.navBarAllURL, "the URL of \"All servers\" button")
|
||||
bgpmapInfo := flag.String("bgpmap-info", settingDefault.bgpmapInfo, "the infos displayed in bgpmap, separated by comma, start with \":\" means allow multiline")
|
||||
telegramBotNamePtr := flag.String("telegram-bot-name", settingDefault.telegramBotName, "telegram bot name (used to filter @bot commands)")
|
||||
protocolFilterPtr := flag.String("protocol-filter", strings.Join(settingDefault.protocolFilter, ","),
|
||||
"protocol types to show in summary tables (comma separated list); defaults to all if not set")
|
||||
@@ -148,6 +154,7 @@ func main() {
|
||||
*navBarBrandURLPtr,
|
||||
*navBarAllServerPtr,
|
||||
*navBarAllURL,
|
||||
*bgpmapInfo,
|
||||
*telegramBotNamePtr,
|
||||
protocolFilter,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user