@@ -104,10 +104,10 @@ This NPEP proposes adding a new type of `AdminNetworkPolicyEgressPeer` called
104
104
105
105
``` golang
106
106
107
- // Domain describes one or more DNS names to be used as a peer.
107
+ // DomainName describes one or more domain names to be used as a peer.
108
108
//
109
- // Domain can be an exact match, or use the wildcard specifier '*' to match one
110
- // or more labels.
109
+ // DomainName can be an exact match, or use the wildcard specifier '*' to match
110
+ // one or more labels.
111
111
//
112
112
// '*', the wildcard specifier, matches one or more entire labels. It does not
113
113
// support partial matches. '*' may only be specified as a prefix.
@@ -124,24 +124,24 @@ This NPEP proposes adding a new type of `AdminNetworkPolicyEgressPeer` called
124
124
// "wikipedia.org" do not.
125
125
//
126
126
// +kubebuilder:validation:Pattern=`^(\*\.)?([a-zA-z0-9]([-a-zA-Z0-9_]*[a-zA-Z0-9])?\.)+[a-zA-z0-9]([-a-zA-Z0-9_]*[a-zA-Z0-9])?\.?$`
127
- type Domain string
127
+ type DomainName string
128
128
129
129
type AdminNetworkPolicyEgressPeer struct {
130
130
<snipped>
131
- // Domains provides a way to specify domain names as peers.
132
- //
133
- // Domains is only supported for ALLOW rules. In order to control access,
134
- // Domain ALLOW rules should be used with a lower priority egress deny --
135
- // this allows the admin to maintain an explicit "allowlist" of reachable
136
- // domains.
137
- //
131
+ // DomainNames provides a way to specify domain names as peers.
132
+ //
133
+ // DomainNames is only supported for ALLOW rules. In order to control
134
+ // access, DomainNames ALLOW rules should be used with a lower priority
135
+ // egress deny -- this allows the admin to maintain an explicit "allowlist"
136
+ // of reachable domains.
137
+ //
138
138
// Support: Extended
139
139
//
140
140
// <network-policy-api:experimental>
141
141
// +optional
142
142
// +listType=set
143
143
// +kubebuilder:validation:MinItems=1
144
- Domains []Domain ` json:"domains ,omitempty"`
144
+ DomainNames []Domain ` json:"domainNames ,omitempty"`
145
145
}
146
146
```
147
147
@@ -164,7 +164,7 @@ spec:
164
164
- name : " allow-to-my-service"
165
165
action : " Allow"
166
166
to :
167
- - domains :
167
+ - domainNames :
168
168
- " my-service.com"
169
169
- " *.cloud-provider.io"
170
170
ports :
@@ -194,7 +194,7 @@ spec:
194
194
- name: "allow-to-my-service"
195
195
action: "Allow"
196
196
to:
197
- - domains :
197
+ - domainNames :
198
198
- "my-service.com"
199
199
- "*.cloud-provider.io"
200
200
ports:
@@ -225,7 +225,7 @@ spec:
225
225
- name: "allow-to-my-service"
226
226
action: "Allow"
227
227
to:
228
- - domains :
228
+ - domainNames :
229
229
- "my-service.com"
230
230
- "*.cloud-provider.io"
231
231
ports:
0 commit comments