Skip to content

Commit 6a1fcd2

Browse files
committed
address review comments
1 parent d8c4b31 commit 6a1fcd2

File tree

8 files changed

+199
-71
lines changed

8 files changed

+199
-71
lines changed

api/networking/v1alpha1/virtualip_types.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import (
99
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
1010
)
1111

12-
// VirtualIPSpec defines the desired state of VirtualIP
12+
// VirtualIPSpec defines the desired state of a VirtualIP
1313
type VirtualIPSpec struct {
1414
// Type is the type of VirtualIP.
1515
Type VirtualIPType `json:"type"`
@@ -66,7 +66,7 @@ type VirtualIPList struct {
6666
}
6767

6868
type EphemeralVirtualIPSpec struct {
69-
// VirtualIPSpec defines the desired state of VirtualIP
69+
// VirtualIPSpec defines the desired state of a VirtualIP
7070
VirtualIPSpec `json:",inline"`
7171
// ReclaimPolicy is the ReclaimPolicyType of virtualIP
7272
ReclaimPolicy ReclaimPolicyType `json:"reclaimPolicy,omitempty"`

client-go/applyconfigurations/networking/v1alpha1/ephemeralvirtualipspec.go

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

client-go/openapi/zz_generated.openapi.go

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/api-reference/networking.md

Lines changed: 84 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -979,6 +979,52 @@ VirtualIPTemplateSpec
979979
</tr>
980980
</tbody>
981981
</table>
982+
<h3 id="networking.ironcore.dev/v1alpha1.EphemeralVirtualIPSpec">EphemeralVirtualIPSpec
983+
</h3>
984+
<p>
985+
(<em>Appears on:</em><a href="#networking.ironcore.dev/v1alpha1.VirtualIPTemplateSpec">VirtualIPTemplateSpec</a>)
986+
</p>
987+
<div>
988+
</div>
989+
<table>
990+
<thead>
991+
<tr>
992+
<th>Field</th>
993+
<th>Description</th>
994+
</tr>
995+
</thead>
996+
<tbody>
997+
<tr>
998+
<td>
999+
<code>VirtualIPSpec</code><br/>
1000+
<em>
1001+
<a href="#networking.ironcore.dev/v1alpha1.VirtualIPSpec">
1002+
VirtualIPSpec
1003+
</a>
1004+
</em>
1005+
</td>
1006+
<td>
1007+
<p>
1008+
(Members of <code>VirtualIPSpec</code> are embedded into this type.)
1009+
</p>
1010+
<p>VirtualIPSpec defines the desired state of a VirtualIP</p>
1011+
</td>
1012+
</tr>
1013+
<tr>
1014+
<td>
1015+
<code>reclaimPolicy</code><br/>
1016+
<em>
1017+
<a href="#networking.ironcore.dev/v1alpha1.ReclaimPolicyType">
1018+
ReclaimPolicyType
1019+
</a>
1020+
</em>
1021+
</td>
1022+
<td>
1023+
<p>ReclaimPolicy is the ReclaimPolicyType of virtualIP</p>
1024+
</td>
1025+
</tr>
1026+
</tbody>
1027+
</table>
9821028
<h3 id="networking.ironcore.dev/v1alpha1.IPBlock">IPBlock
9831029
</h3>
9841030
<p>
@@ -2801,6 +2847,29 @@ EphemeralPrefixSource
28012847
</tr>
28022848
</tbody>
28032849
</table>
2850+
<h3 id="networking.ironcore.dev/v1alpha1.ReclaimPolicyType">ReclaimPolicyType
2851+
(<code>string</code> alias)</h3>
2852+
<p>
2853+
(<em>Appears on:</em><a href="#networking.ironcore.dev/v1alpha1.EphemeralVirtualIPSpec">EphemeralVirtualIPSpec</a>)
2854+
</p>
2855+
<div>
2856+
<p>ReclaimPolicyType is the ironcore ReclaimPolicy of a VirtualIP.</p>
2857+
</div>
2858+
<table>
2859+
<thead>
2860+
<tr>
2861+
<th>Value</th>
2862+
<th>Description</th>
2863+
</tr>
2864+
</thead>
2865+
<tbody><tr><td><p>&#34;Delete&#34;</p></td>
2866+
<td><p>ReclaimPolicyTypeDelete is used for any VirtualIP that is deleted when the claim of VirtualIP is released.</p>
2867+
</td>
2868+
</tr><tr><td><p>&#34;Retain&#34;</p></td>
2869+
<td><p>ReclaimPolicyTypeRetain is used for any VirtualIP that is retained when the claim of VirtualIP is released.</p>
2870+
</td>
2871+
</tr></tbody>
2872+
</table>
28042873
<h3 id="networking.ironcore.dev/v1alpha1.VirtualIPSource">VirtualIPSource
28052874
</h3>
28062875
<p>
@@ -2849,10 +2918,10 @@ VirtualIP.</p>
28492918
<h3 id="networking.ironcore.dev/v1alpha1.VirtualIPSpec">VirtualIPSpec
28502919
</h3>
28512920
<p>
2852-
(<em>Appears on:</em><a href="#networking.ironcore.dev/v1alpha1.VirtualIP">VirtualIP</a>, <a href="#networking.ironcore.dev/v1alpha1.VirtualIPTemplateSpec">VirtualIPTemplateSpec</a>)
2921+
(<em>Appears on:</em><a href="#networking.ironcore.dev/v1alpha1.VirtualIP">VirtualIP</a>, <a href="#networking.ironcore.dev/v1alpha1.EphemeralVirtualIPSpec">EphemeralVirtualIPSpec</a>)
28532922
</p>
28542923
<div>
2855-
<p>VirtualIPSpec defines the desired state of VirtualIP</p>
2924+
<p>VirtualIPSpec defines the desired state of a VirtualIP</p>
28562925
</div>
28572926
<table>
28582927
<thead>
@@ -2968,8 +3037,8 @@ Refer to the Kubernetes API documentation for the fields of the
29683037
<td>
29693038
<code>spec</code><br/>
29703039
<em>
2971-
<a href="#networking.ironcore.dev/v1alpha1.VirtualIPSpec">
2972-
VirtualIPSpec
3040+
<a href="#networking.ironcore.dev/v1alpha1.EphemeralVirtualIPSpec">
3041+
EphemeralVirtualIPSpec
29733042
</a>
29743043
</em>
29753044
</td>
@@ -2979,41 +3048,31 @@ VirtualIPSpec
29793048
<table>
29803049
<tr>
29813050
<td>
2982-
<code>type</code><br/>
2983-
<em>
2984-
<a href="#networking.ironcore.dev/v1alpha1.VirtualIPType">
2985-
VirtualIPType
2986-
</a>
2987-
</em>
2988-
</td>
2989-
<td>
2990-
<p>Type is the type of VirtualIP.</p>
2991-
</td>
2992-
</tr>
2993-
<tr>
2994-
<td>
2995-
<code>ipFamily</code><br/>
3051+
<code>VirtualIPSpec</code><br/>
29963052
<em>
2997-
<a href="https://kubernetes.io/docs/reference/generated/kubernetes-api/v1.27/#ipfamily-v1-core">
2998-
Kubernetes core/v1.IPFamily
3053+
<a href="#networking.ironcore.dev/v1alpha1.VirtualIPSpec">
3054+
VirtualIPSpec
29993055
</a>
30003056
</em>
30013057
</td>
30023058
<td>
3003-
<p>IPFamily is the ip family of the VirtualIP.</p>
3059+
<p>
3060+
(Members of <code>VirtualIPSpec</code> are embedded into this type.)
3061+
</p>
3062+
<p>VirtualIPSpec defines the desired state of a VirtualIP</p>
30043063
</td>
30053064
</tr>
30063065
<tr>
30073066
<td>
3008-
<code>targetRef</code><br/>
3067+
<code>reclaimPolicy</code><br/>
30093068
<em>
3010-
<a href="../common/#common.ironcore.dev/v1alpha1.LocalUIDReference">
3011-
github.com/ironcore-dev/ironcore/api/common/v1alpha1.LocalUIDReference
3069+
<a href="#networking.ironcore.dev/v1alpha1.ReclaimPolicyType">
3070+
ReclaimPolicyType
30123071
</a>
30133072
</em>
30143073
</td>
30153074
<td>
3016-
<p>TargetRef references the target for this VirtualIP (currently only NetworkInterface).</p>
3075+
<p>ReclaimPolicy is the ReclaimPolicyType of virtualIP</p>
30173076
</td>
30183077
</tr>
30193078
</table>

gen/swagger.json

Lines changed: 32 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65791,6 +65791,36 @@
6579165791
}
6579265792
}
6579365793
},
65794+
"com.github.ironcore-dev.ironcore.api.networking.v1alpha1.EphemeralVirtualIPSpec": {
65795+
"type": "object",
65796+
"required": [
65797+
"type",
65798+
"ipFamily"
65799+
],
65800+
"properties": {
65801+
"ipFamily": {
65802+
"description": "IPFamily is the ip family of the VirtualIP.\n\nPossible enum values:\n - `\"\"` indicates that this IP is unknown protocol\n - `\"IPv4\"` indicates that this IP is IPv4 protocol\n - `\"IPv6\"` indicates that this IP is IPv6 protocol",
65803+
"type": "string",
65804+
"enum": [
65805+
"",
65806+
"IPv4",
65807+
"IPv6"
65808+
]
65809+
},
65810+
"reclaimPolicy": {
65811+
"description": "ReclaimPolicy is the ReclaimPolicyType of virtualIP",
65812+
"type": "string"
65813+
},
65814+
"targetRef": {
65815+
"description": "TargetRef references the target for this VirtualIP (currently only NetworkInterface).",
65816+
"$ref": "#/definitions/com.github.ironcore-dev.ironcore.api.common.v1alpha1.LocalUIDReference"
65817+
},
65818+
"type": {
65819+
"description": "Type is the type of VirtualIP.",
65820+
"type": "string"
65821+
}
65822+
}
65823+
},
6579465824
"com.github.ironcore-dev.ironcore.api.networking.v1alpha1.IPBlock": {
6579565825
"description": "IPBlock specifies an ip block with optional exceptions.",
6579665826
"type": "object",
@@ -66926,7 +66956,7 @@
6692666956
}
6692766957
},
6692866958
"com.github.ironcore-dev.ironcore.api.networking.v1alpha1.VirtualIPSpec": {
66929-
"description": "VirtualIPSpec defines the desired state of VirtualIP",
66959+
"description": "VirtualIPSpec defines the desired state of a VirtualIP",
6693066960
"type": "object",
6693166961
"required": [
6693266962
"type",
@@ -66970,7 +67000,7 @@
6697067000
"$ref": "#/definitions/io.k8s.apimachinery.pkg.apis.meta.v1.ObjectMeta"
6697167001
},
6697267002
"spec": {
66973-
"$ref": "#/definitions/com.github.ironcore-dev.ironcore.api.networking.v1alpha1.VirtualIPSpec"
67003+
"$ref": "#/definitions/com.github.ironcore-dev.ironcore.api.networking.v1alpha1.EphemeralVirtualIPSpec"
6697467004
}
6697567005
}
6697667006
},

gen/v3/apis__compute.ironcore.dev__v1alpha1_openapi.json

Lines changed: 37 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -5027,6 +5027,42 @@
50275027
}
50285028
}
50295029
},
5030+
"com.github.ironcore-dev.ironcore.api.networking.v1alpha1.EphemeralVirtualIPSpec": {
5031+
"type": "object",
5032+
"required": [
5033+
"type",
5034+
"ipFamily"
5035+
],
5036+
"properties": {
5037+
"ipFamily": {
5038+
"description": "IPFamily is the ip family of the VirtualIP.\n\nPossible enum values:\n - `\"\"` indicates that this IP is unknown protocol\n - `\"IPv4\"` indicates that this IP is IPv4 protocol\n - `\"IPv6\"` indicates that this IP is IPv6 protocol",
5039+
"type": "string",
5040+
"default": "",
5041+
"enum": [
5042+
"",
5043+
"IPv4",
5044+
"IPv6"
5045+
]
5046+
},
5047+
"reclaimPolicy": {
5048+
"description": "ReclaimPolicy is the ReclaimPolicyType of virtualIP",
5049+
"type": "string"
5050+
},
5051+
"targetRef": {
5052+
"description": "TargetRef references the target for this VirtualIP (currently only NetworkInterface).",
5053+
"allOf": [
5054+
{
5055+
"$ref": "#/components/schemas/com.github.ironcore-dev.ironcore.api.common.v1alpha1.LocalUIDReference"
5056+
}
5057+
]
5058+
},
5059+
"type": {
5060+
"description": "Type is the type of VirtualIP.",
5061+
"type": "string",
5062+
"default": ""
5063+
}
5064+
}
5065+
},
50305066
"com.github.ironcore-dev.ironcore.api.networking.v1alpha1.IPSource": {
50315067
"description": "IPSource is the definition of how to obtain an IP.",
50325068
"type": "object",
@@ -5199,39 +5235,6 @@
51995235
}
52005236
}
52015237
},
5202-
"com.github.ironcore-dev.ironcore.api.networking.v1alpha1.VirtualIPSpec": {
5203-
"description": "VirtualIPSpec defines the desired state of VirtualIP",
5204-
"type": "object",
5205-
"required": [
5206-
"type",
5207-
"ipFamily"
5208-
],
5209-
"properties": {
5210-
"ipFamily": {
5211-
"description": "IPFamily is the ip family of the VirtualIP.\n\nPossible enum values:\n - `\"\"` indicates that this IP is unknown protocol\n - `\"IPv4\"` indicates that this IP is IPv4 protocol\n - `\"IPv6\"` indicates that this IP is IPv6 protocol",
5212-
"type": "string",
5213-
"default": "",
5214-
"enum": [
5215-
"",
5216-
"IPv4",
5217-
"IPv6"
5218-
]
5219-
},
5220-
"targetRef": {
5221-
"description": "TargetRef references the target for this VirtualIP (currently only NetworkInterface).",
5222-
"allOf": [
5223-
{
5224-
"$ref": "#/components/schemas/com.github.ironcore-dev.ironcore.api.common.v1alpha1.LocalUIDReference"
5225-
}
5226-
]
5227-
},
5228-
"type": {
5229-
"description": "Type is the type of VirtualIP.",
5230-
"type": "string",
5231-
"default": ""
5232-
}
5233-
}
5234-
},
52355238
"com.github.ironcore-dev.ironcore.api.networking.v1alpha1.VirtualIPTemplateSpec": {
52365239
"description": "VirtualIPTemplateSpec is the specification of a VirtualIP template.",
52375240
"type": "object",
@@ -5248,7 +5251,7 @@
52485251
"default": {},
52495252
"allOf": [
52505253
{
5251-
"$ref": "#/components/schemas/com.github.ironcore-dev.ironcore.api.networking.v1alpha1.VirtualIPSpec"
5254+
"$ref": "#/components/schemas/com.github.ironcore-dev.ironcore.api.networking.v1alpha1.EphemeralVirtualIPSpec"
52525255
}
52535256
]
52545257
}

0 commit comments

Comments
 (0)