Skip to content

Commit c5677f5

Browse files
Add allowedprojects spec
1 parent 78046b4 commit c5677f5

4 files changed

Lines changed: 32 additions & 0 deletions

File tree

api/v1/hypervisor_types.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,12 @@ type HypervisorSpec struct {
9393
// Aggregates are used to apply aggregates to the hypervisor.
9494
Aggregates []string `json:"aggregates"`
9595

96+
// +kubebuilder:default:={}
97+
// AllowedProjects defines which openstack projects are allowed to schedule
98+
// instances on this hypervisor. The values of this list should be project
99+
// uuids. If left empty, all projects are allowed.
100+
AllowedProjects []string `json:"allowedProjects"`
101+
96102
// +kubebuilder:default:=true
97103
// HighAvailability is used to enable the high availability handling of the hypervisor.
98104
HighAvailability bool `json:"highAvailability"`

api/v1/zz_generated.deepcopy.go

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

applyconfigurations/api/v1/hypervisorspec.go

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

config/crd/bases/kvm.cloud.sap_hypervisors.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,15 @@ spec:
110110
items:
111111
type: string
112112
type: array
113+
allowedProjects:
114+
default: []
115+
description: |-
116+
AllowedProjects defines which openstack projects are allowed to schedule
117+
instances on this hypervisor. The values of this list should be project
118+
uuids. If left empty, all projects are allowed.
119+
items:
120+
type: string
121+
type: array
113122
createCertManagerCertificate:
114123
default: false
115124
description: |-
@@ -167,6 +176,7 @@ spec:
167176
type: string
168177
required:
169178
- aggregates
179+
- allowedProjects
170180
- createCertManagerCertificate
171181
- customTraits
172182
- evacuateOnReboot

0 commit comments

Comments
 (0)