mirror of
https://github.com/gravitl/netmaker.git
synced 2025-10-21 16:09:59 +08:00
add ACL management
This commit is contained in:
16
cli/functions/acl.go
Normal file
16
cli/functions/acl.go
Normal file
@@ -0,0 +1,16 @@
|
||||
package functions
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"net/http"
|
||||
|
||||
"github.com/gravitl/netmaker/logic/acls"
|
||||
)
|
||||
|
||||
func GetACL(networkName string) *acls.ACLContainer {
|
||||
return request[acls.ACLContainer](http.MethodGet, fmt.Sprintf("/api/networks/%s/acls", networkName), nil)
|
||||
}
|
||||
|
||||
func UpdateACL(networkName string, payload *acls.ACLContainer) *acls.ACLContainer {
|
||||
return request[acls.ACLContainer](http.MethodPut, fmt.Sprintf("/api/networks/%s/acls", networkName), payload)
|
||||
}
|
Reference in New Issue
Block a user