Skip to content

Commit 6122c94

Browse files
author
Anwar Hassen
committed
Add resource shortNames
Signed-off-by: Anwar Hassen <[email protected]>
1 parent edea569 commit 6122c94

9 files changed

+12
-6
lines changed

api/v1alpha3/openstackcluster_types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ type OpenStackClusterStatus struct {
140140
}
141141

142142
// +kubebuilder:object:root=true
143-
// +kubebuilder:resource:path=openstackclusters,scope=Namespaced,categories=cluster-api
143+
// +kubebuilder:resource:path=openstackclusters,scope=Namespaced,categories=cluster-api,shortName=osc
144144
// +kubebuilder:subresource:status
145145
// +kubebuilder:printcolumn:name="Cluster",type="string",JSONPath=".metadata.labels.cluster\\.x-k8s\\.io/cluster-name",description="Cluster to which this OpenStackCluster belongs"
146146
// +kubebuilder:printcolumn:name="Ready",type="string",JSONPath=".status.ready",description="Cluster infrastructure is ready for OpenStack instances"

api/v1alpha3/openstackmachine_types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ type OpenStackMachineStatus struct {
128128
}
129129

130130
// +kubebuilder:object:root=true
131-
// +kubebuilder:resource:path=openstackmachines,scope=Namespaced,categories=cluster-api
131+
// +kubebuilder:resource:path=openstackmachines,scope=Namespaced,categories=cluster-api,shortName=osm
132132
// +kubebuilder:subresource:status
133133
// +kubebuilder:printcolumn:name="Cluster",type="string",JSONPath=".metadata.labels.cluster\\.x-k8s\\.io/cluster-name",description="Cluster to which this OpenStackMachine belongs"
134134
// +kubebuilder:printcolumn:name="InstanceState",type="string",JSONPath=".status.instanceState",description="OpenStack instance state"

api/v1alpha3/openstackmachinetemplate_types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ type OpenStackMachineTemplateSpec struct {
2626
}
2727

2828
// +kubebuilder:object:root=true
29-
// +kubebuilder:resource:path=openstackmachinetemplates,scope=Namespaced,categories=cluster-api
29+
// +kubebuilder:resource:path=openstackmachinetemplates,scope=Namespaced,categories=cluster-api,shortName=osmt
3030

3131
// OpenStackMachineTemplate is the Schema for the openstackmachinetemplates API.
3232
type OpenStackMachineTemplate struct {

api/v1alpha4/openstackcluster_types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ type OpenStackClusterStatus struct {
136136
}
137137

138138
// +kubebuilder:object:root=true
139-
// +kubebuilder:resource:path=openstackclusters,scope=Namespaced,categories=cluster-api
139+
// +kubebuilder:resource:path=openstackclusters,scope=Namespaced,categories=cluster-api,shortName=osc
140140
// +kubebuilder:storageversion
141141
// +kubebuilder:subresource:status
142142
// +kubebuilder:printcolumn:name="Cluster",type="string",JSONPath=".metadata.labels.cluster\\.x-k8s\\.io/cluster-name",description="Cluster to which this OpenStackCluster belongs"

api/v1alpha4/openstackmachine_types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ type OpenStackMachineStatus struct {
125125
}
126126

127127
// +kubebuilder:object:root=true
128-
// +kubebuilder:resource:path=openstackmachines,scope=Namespaced,categories=cluster-api
128+
// +kubebuilder:resource:path=openstackmachines,scope=Namespaced,categories=cluster-api,shortName=osm
129129
// +kubebuilder:storageversion
130130
// +kubebuilder:subresource:status
131131
// +kubebuilder:printcolumn:name="Cluster",type="string",JSONPath=".metadata.labels.cluster\\.x-k8s\\.io/cluster-name",description="Cluster to which this OpenStackMachine belongs"

api/v1alpha4/openstackmachinetemplate_types.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ type OpenStackMachineTemplateSpec struct {
2626
}
2727

2828
// +kubebuilder:object:root=true
29-
// +kubebuilder:resource:path=openstackmachinetemplates,scope=Namespaced,categories=cluster-api
29+
// +kubebuilder:resource:path=openstackmachinetemplates,scope=Namespaced,categories=cluster-api,shortName=osmt
3030
// +kubebuilder:storageversion
3131

3232
// OpenStackMachineTemplate is the Schema for the openstackmachinetemplates API.

config/crd/bases/infrastructure.cluster.x-k8s.io_openstackclusters.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ spec:
1515
kind: OpenStackCluster
1616
listKind: OpenStackClusterList
1717
plural: openstackclusters
18+
shortNames:
19+
- osc
1820
singular: openstackcluster
1921
scope: Namespaced
2022
versions:

config/crd/bases/infrastructure.cluster.x-k8s.io_openstackmachines.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ spec:
1515
kind: OpenStackMachine
1616
listKind: OpenStackMachineList
1717
plural: openstackmachines
18+
shortNames:
19+
- osm
1820
singular: openstackmachine
1921
scope: Namespaced
2022
versions:

config/crd/bases/infrastructure.cluster.x-k8s.io_openstackmachinetemplates.yaml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ spec:
1515
kind: OpenStackMachineTemplate
1616
listKind: OpenStackMachineTemplateList
1717
plural: openstackmachinetemplates
18+
shortNames:
19+
- osmt
1820
singular: openstackmachinetemplate
1921
scope: Namespaced
2022
versions:

0 commit comments

Comments
 (0)