Compare commits
2 Commits
66d460dbfc
...
efa9abb289
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
efa9abb289 | ||
|
|
2747abfc04 |
1
internal/actions/email.go
Normal file
1
internal/actions/email.go
Normal file
@@ -0,0 +1 @@
|
|||||||
|
package actions
|
||||||
1
internal/actions/scripts.go
Normal file
1
internal/actions/scripts.go
Normal file
@@ -0,0 +1 @@
|
|||||||
|
package actions
|
||||||
@@ -31,9 +31,29 @@ type Rule struct {
|
|||||||
Method string `toml:"method"`
|
Method string `toml:"method"`
|
||||||
MaxRetry int `toml:"max_retry"`
|
MaxRetry int `toml:"max_retry"`
|
||||||
BanTime string `toml:"ban_time"`
|
BanTime string `toml:"ban_time"`
|
||||||
|
Action []Action
|
||||||
}
|
}
|
||||||
|
|
||||||
type Metrics struct {
|
type Metrics struct {
|
||||||
Enabled bool `toml:"enabled"`
|
Enabled bool `toml:"enabled"`
|
||||||
Port int `toml:"port"`
|
Port int `toml:"port"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Actions
|
||||||
|
type Action struct {
|
||||||
|
Type string `toml:"type"`
|
||||||
|
Enabled bool `toml:"enabled"`
|
||||||
|
URL string `toml:"url"`
|
||||||
|
Headers map[string]string `toml:"headers"`
|
||||||
|
Body string `toml:"body"`
|
||||||
|
Email string `toml:"email"`
|
||||||
|
EmailSender string `toml:"email_sender"`
|
||||||
|
EmailSubject string `toml:"email_subject"`
|
||||||
|
SMTPHost string `toml:"smtp_host"`
|
||||||
|
SMTPPort int `toml:"smtp_port"`
|
||||||
|
SMTPUser string `toml:"smtp_user"`
|
||||||
|
SMTPPassword string `toml:"smtp_password"`
|
||||||
|
SMTPTLS bool `toml:"smtp_tls"`
|
||||||
|
Interpretator string `toml:"interpretator"`
|
||||||
|
Script string `toml:"script"`
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user