Documentation ¶
Index ¶
- Constants
- Variables
- func ConstructAllowAll(data []interface{}) (allowAll *policyrecipenetworkmodel.V1alpha1CommonPolicySpecNetworkV1AllowAll)
- func ConstructAllowAllToPods(data []interface{}) (...)
- func ConstructCustomEgress(data []interface{}) (...)
- func ConstructCustomIngress(data []interface{}) (...)
- func ConstructDenyAllToPods(data []interface{}) (...)
- func FlattenAllowAll(allowAll *policyrecipenetworkmodel.V1alpha1CommonPolicySpecNetworkV1AllowAll) (data []interface{})
- func FlattenAllowAllToPods(...) (data []interface{})
- func FlattenCustomEgress(...) (data []interface{})
- func FlattenCustomIngress(...) (data []interface{})
- func FlattenDenyAllToPods(...) (data []interface{})
Constants ¶
View Source
const ( AllowAllKey = "allow_all" AllowAllToPodsKey = "allow_all_to_pods" AllowAllEgressKey = "allow_all_egress" DenyAllKey = "deny_all" DenyAllToPodsKey = "deny_all_to_pods" DenyAllEgressKey = "deny_all_egress" CustomEgressKey = "custom_egress" CustomIngressKey = "custom_ingress" FromOwnNamespaceKey = "from_own_namespace" ToPodLabelsKey = "to_pod_labels" LabelKey = "key" LabelValueKey = "value" IPBlock = "ipBlock" PodSelector = "podSelector" NamespaceSelector = "namespaceSelector" )
Variables ¶
View Source
var AllowAll = &schema.Schema{ Type: schema.TypeList, Description: "The input schema for network policy allow-all recipe version v1", Optional: true, ForceNew: true, MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ FromOwnNamespaceKey: { Type: schema.TypeBool, Description: "Allow traffic only from own namespace. Allow traffic only from pods in the same namespace as the destination pod.", Optional: true, Default: false, }, }, }, }
View Source
var AllowAllEgress = &schema.Schema{ Type: schema.TypeList, Description: "The input schema for network policy allow-all-egress recipe version v1", Optional: true, ForceNew: true, MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{}, }, }
View Source
var AllowAllToPods = &schema.Schema{ Type: schema.TypeList, Description: "The input schema for network policy allow-all-to-pods recipe version v1", Optional: true, ForceNew: true, MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ FromOwnNamespaceKey: { Type: schema.TypeBool, Description: "Allow traffic only from own namespace. Allow traffic only from pods in the same namespace as the destination pod.", Optional: true, Default: false, }, ToPodLabelsKey: toPodLabel, }, }, }
View Source
var ( CustomEgress = &schema.Schema{ Type: schema.TypeList, Description: "The input schema for network policy custom egress recipe version v1", Optional: true, ForceNew: true, MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ rulesKey: { Type: schema.TypeList, Description: "This specifies list of egress rules to be applied to the selected pods.", Required: true, MinItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ portsKey: { Type: schema.TypeList, Description: "List of destination ports for outgoing traffic. Each item in this list is combined using a logical OR. Default is this rule matches all ports (traffic not restricted by port).", Required: true, MinItems: 1, Elem: port, }, ruleSpecKey: { Type: schema.TypeList, Description: "List of destinations for outgoing traffic of pods selected for this rule. Default is the rule matches all destinations (traffic not restricted by destinations).", Required: true, MinItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ ruleSpecIPKey: ruleSpecIPDestination, ruleSpecSelectorKey: ruleSpecSelectorDestination, }, }, }, }, }, }, ToPodLabelsKey: toPodLabel, }, }, } )
View Source
var ( CustomIngress = &schema.Schema{ Type: schema.TypeList, Description: "The input schema for network policy custom ingress recipe version v1", Optional: true, ForceNew: true, MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ rulesKey: { Type: schema.TypeList, Description: "This specifies list of ingress rules to be applied to the selected pods.", Required: true, MinItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ portsKey: { Type: schema.TypeList, Description: "List of ports which should be made accessible on the pods selected for this rule. Each item in this list is combined using a logical OR. Default is this rule matches all ports (traffic not restricted by port).", Required: true, MinItems: 1, Elem: port, }, ruleSpecKey: { Type: schema.TypeList, Description: "List of sources which should be able to access the pods selected for this rule. Default is the rule matches all sources (traffic not restricted by source). List of items of type V1alpha1CommonPolicySpecNetworkV1CustomIngressRulesRuleSpec0 OR V1alpha1CommonPolicySpecNetworkV1CustomIngressRulesRuleSpec1.", Required: true, MinItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{ ruleSpecIPKey: ruleSpecIPSource, ruleSpecSelectorKey: ruleSpecSelectorSource, }, }, }, }, }, }, ToPodLabelsKey: toPodLabel, }, }, } )
View Source
var DenyAll = &schema.Schema{ Type: schema.TypeList, Description: "The input schema for network policy deny-all recipe version v1", Optional: true, ForceNew: true, MaxItems: 1, Elem: &schema.Resource{ Schema: map[string]*schema.Schema{}, }, }
Functions ¶
func ConstructAllowAll ¶
func ConstructAllowAll(data []interface{}) (allowAll *policyrecipenetworkmodel.V1alpha1CommonPolicySpecNetworkV1AllowAll)
func ConstructAllowAllToPods ¶
func ConstructAllowAllToPods(data []interface{}) (allowAllToPods *policyrecipenetworkmodel.V1alpha1CommonPolicySpecNetworkV1AllowAllToPods)
func ConstructCustomEgress ¶
func ConstructCustomEgress(data []interface{}) (customEgress *policyrecipenetworkmodel.V1alpha1CommonPolicySpecNetworkV1CustomEgress)
func ConstructCustomIngress ¶
func ConstructCustomIngress(data []interface{}) (customIngress *policyrecipenetworkmodel.V1alpha1CommonPolicySpecNetworkV1CustomIngress)
func ConstructDenyAllToPods ¶
func ConstructDenyAllToPods(data []interface{}) (denyAllToPods *policyrecipenetworkmodel.V1alpha1CommonPolicySpecNetworkV1DenyAllToPods)
func FlattenAllowAll ¶
func FlattenAllowAll(allowAll *policyrecipenetworkmodel.V1alpha1CommonPolicySpecNetworkV1AllowAll) (data []interface{})
func FlattenAllowAllToPods ¶
func FlattenAllowAllToPods(allowAllToPods *policyrecipenetworkmodel.V1alpha1CommonPolicySpecNetworkV1AllowAllToPods) (data []interface{})
func FlattenCustomEgress ¶
func FlattenCustomEgress(customEgress *policyrecipenetworkmodel.V1alpha1CommonPolicySpecNetworkV1CustomEgress) (data []interface{})
func FlattenCustomIngress ¶
func FlattenCustomIngress(customIngress *policyrecipenetworkmodel.V1alpha1CommonPolicySpecNetworkV1CustomIngress) (data []interface{})
func FlattenDenyAllToPods ¶
func FlattenDenyAllToPods(denyAllToPods *policyrecipenetworkmodel.V1alpha1CommonPolicySpecNetworkV1DenyAllToPods) (data []interface{})
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.