make slack channel configurable
This commit is contained in:
parent
def0a97f49
commit
4af5c2f4c6
1 changed files with 2 additions and 1 deletions
|
@ -25,6 +25,7 @@ type Config struct {
|
|||
BucketName string `json:"bucket_name"`
|
||||
DBConn string `json:"db_conn"`
|
||||
SlackHookURL string `json:"slack_hook_url"`
|
||||
SlackChannel string `json:"slack_channel"`
|
||||
UpdateBinURL string `json:"update_bin_url"`
|
||||
UpdateCmd string `json:"update_cmd"`
|
||||
}
|
||||
|
@ -102,7 +103,7 @@ func preRun(cmd *cobra.Command, args []string) {
|
|||
hook := &slackrus.SlackrusHook{
|
||||
HookURL: globalConfig.SlackHookURL,
|
||||
AcceptedLevels: slackrus.LevelThreshold(logrus.InfoLevel),
|
||||
Channel: "#reflector-logs",
|
||||
Channel: globalConfig.SlackChannel,
|
||||
//IconEmoji: ":ghost:",
|
||||
//Username: "reflector.go",
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue