Fix append to policy name, shouldn't be rule name
This commit is contained in:
parent
f2327b1c1d
commit
0304fc8fea
@ -51,10 +51,10 @@ func config(redirects []Redirect) error {
|
||||
// Iterate over values in the policy map and output the policy configuration
|
||||
fmt.Println("config waf url-rewrite url-rewrite-policy")
|
||||
for policyName, policyRules := range redirectPolicies {
|
||||
fmt.Printf("edit \"%s\"\n", policyName)
|
||||
fmt.Printf("edit \"%s-redirects\"\n", policyName)
|
||||
for _, ruleName := range policyRules {
|
||||
fmt.Println("edit 0")
|
||||
fmt.Printf("set url-rewrite-rule-name %s-redirects\n", ruleName)
|
||||
fmt.Printf("set url-rewrite-rule-name %s\n", ruleName)
|
||||
fmt.Println("next")
|
||||
fmt.Println("end")
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user