Skip to content

Commit 962a5cb

Browse files
Merge pull request #285 from omersch381/add_ns_records_api_fields
Add NsRecords API fields under designateAPI
2 parents 7fc73e6 + 4840fb9 commit 962a5cb

File tree

4 files changed

+78
-0
lines changed

4 files changed

+78
-0
lines changed

api/bases/designate.openstack.org_designates.yaml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1587,6 +1587,26 @@ spec:
15871587
description: NodeSelector to target subset of worker nodes running
15881588
this service
15891589
type: object
1590+
nsRecords:
1591+
description: NSRecords contains the list of nameserver records for
1592+
the Designate pool
1593+
items:
1594+
description: DesignateNSRecord defines a DNS nameserver record
1595+
properties:
1596+
hostname:
1597+
description: Hostname of the nameserver
1598+
minLength: 1
1599+
type: string
1600+
priority:
1601+
description: Priority of the nameserver
1602+
minimum: 1
1603+
type: integer
1604+
required:
1605+
- hostname
1606+
- priority
1607+
type: object
1608+
type: array
1609+
x-kubernetes-list-type: atomic
15901610
passwordSelectors:
15911611
default:
15921612
service: DesignatePassword

api/v1beta1/designate_types.go

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -105,6 +105,19 @@ type DesignateSpec struct {
105105
DesignateUnbound DesignateUnboundSpec `json:"designateUnbound"`
106106
}
107107

108+
// DesignateNSRecord defines a DNS nameserver record
109+
type DesignateNSRecord struct {
110+
// Hostname of the nameserver
111+
// +kubebuilder:validation:Required
112+
// +kubebuilder:validation:MinLength=1
113+
Hostname string `json:"hostname"`
114+
115+
// Priority of the nameserver
116+
// +kubebuilder:validation:Required
117+
// +kubebuilder:validation:Minimum=1
118+
Priority int `json:"priority"`
119+
}
120+
108121
// DesignateSpecBase -
109122
type DesignateSpecBase struct {
110123
// INSERT ADDITIONAL SPEC FIELDS - desired state of cluster
@@ -204,6 +217,11 @@ type DesignateSpecBase struct {
204217
// TopologyRef to apply the Topology defined by the associated CR referenced
205218
// by name
206219
TopologyRef *topologyv1.TopoRef `json:"topologyRef,omitempty"`
220+
221+
// +kubebuilder:validation:Optional
222+
// +listType=atomic
223+
// NSRecords contains the list of nameserver records for the Designate pool
224+
NSRecords []DesignateNSRecord `json:"nsRecords,omitempty"`
207225
}
208226

209227
// DesignateStatus defines the observed state of Designate

api/v1beta1/zz_generated.deepcopy.go

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

config/crd/bases/designate.openstack.org_designates.yaml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1587,6 +1587,26 @@ spec:
15871587
description: NodeSelector to target subset of worker nodes running
15881588
this service
15891589
type: object
1590+
nsRecords:
1591+
description: NSRecords contains the list of nameserver records for
1592+
the Designate pool
1593+
items:
1594+
description: DesignateNSRecord defines a DNS nameserver record
1595+
properties:
1596+
hostname:
1597+
description: Hostname of the nameserver
1598+
minLength: 1
1599+
type: string
1600+
priority:
1601+
description: Priority of the nameserver
1602+
minimum: 1
1603+
type: integer
1604+
required:
1605+
- hostname
1606+
- priority
1607+
type: object
1608+
type: array
1609+
x-kubernetes-list-type: atomic
15901610
passwordSelectors:
15911611
default:
15921612
service: DesignatePassword

0 commit comments

Comments
 (0)