Skip to content

Commit

Permalink
Automatic Update Crossplane Types to v0.16.1 (#44)
Browse files Browse the repository at this point in the history
* Automatic Update Crossplane Types to v0.16.0

* update

---------

Co-authored-by: Jiacheng Xu <[email protected]>
  • Loading branch information
akuitybot and jiachengxu authored Sep 13, 2024
1 parent 8038cbf commit 3a7b2cb
Show file tree
Hide file tree
Showing 9 changed files with 261 additions and 4 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,3 +7,4 @@ cover.out
.vscode
.idea
.DS_Store
dist
8 changes: 8 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -162,3 +162,11 @@ akuity-publish:
us-docker.pkg.dev/akuity/crossplane/provider:$(VERSION)

.PHONY: crossplane.help help-special

.PHONY: generate-kubetypes
generate-kubetypes:
# https://pkg.go.dev/sigs.k8s.io/controller-tools/cmd/controller-gen
GOBIN=`pwd`/dist go install sigs.k8s.io/controller-tools/cmd/[email protected]
./dist/controller-gen object paths="./internal/types/generated/akuity/v1alpha1/..."
./dist/controller-gen object paths="./internal/types/generated/argocd/v1alpha1/..."
./dist/controller-gen object paths="./internal/types/generated/crossplane/v1alpha1/..."
22 changes: 19 additions & 3 deletions internal/types/generated/akuity/v1alpha1/argocdinstance_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,33 @@ import (
"k8s.io/apimachinery/pkg/runtime"
)

//+kubebuilder:object:root=true
//+kubebuilder:subresource:status

// ArgoCD is the Schema for the argocd API
type ArgoCD struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`

Spec ArgoCDSpec `json:"spec,omitempty"`
}

type ArgoCDSpec struct {
Description string `json:"description"`
Version string `json:"version"`
//+kubebuilder:object:root=true

// ArgoCDList contains a list of ArgoCD
type ArgoCDList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []ArgoCD `json:"items"`
}

func init() {
SchemeBuilder.Register(&ArgoCD{}, &ArgoCDList{})
}

type ArgoCDSpec struct {
Description string `json:"description"`
Version string `json:"version"`
InstanceSpec InstanceSpec `json:"instanceSpec,omitempty"`
}

Expand Down
17 changes: 17 additions & 0 deletions internal/types/generated/akuity/v1alpha1/cluster_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,10 @@ import (
"k8s.io/apimachinery/pkg/runtime"
)

//+kubebuilder:object:root=true
//+kubebuilder:subresource:status

// Cluster is the Schema for the cluster API
type Cluster struct {
metav1.TypeMeta `json:",inline"`
metav1.ObjectMeta `json:"metadata,omitempty"`
Expand All @@ -19,6 +23,19 @@ type Cluster struct {

type ClusterSize string

//+kubebuilder:object:root=true

// ClusterList contains a list of Cluster
type ClusterList struct {
metav1.TypeMeta `json:",inline"`
metav1.ListMeta `json:"metadata,omitempty"`
Items []Cluster `json:"items"`
}

func init() {
SchemeBuilder.Register(&Cluster{}, &ClusterList{})
}

type ClusterSpec struct {
Description string `json:"description,omitempty"`
NamespaceScoped bool `json:"namespaceScoped,omitempty"`
Expand Down
136 changes: 135 additions & 1 deletion internal/types/generated/akuity/v1alpha1/zz_generated.deepcopy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,11 @@ type ArgoCD struct {
Spec ArgoCDSpec `json:"spec,omitempty"`
}

// +kubebuilder:object:generate=true
type ArgoCDList struct {
Items []ArgoCD `json:"items"`
}

// +kubebuilder:object:generate=true
type ArgoCDSpec struct {
Description string `json:"description,omitempty"`
Expand Down
5 changes: 5 additions & 0 deletions internal/types/generated/crossplane/v1alpha1/cluster_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ type Cluster struct {
Spec ClusterSpec `json:"spec,omitempty"`
}

// +kubebuilder:object:generate=true
type ClusterList struct {
Items []Cluster `json:"items"`
}

// +kubebuilder:object:generate=true
type ClusterSpec struct {
Description string `json:"description,omitempty"`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,11 @@ type ConfigManagementPlugin struct {
Spec PluginSpec `json:"spec,omitempty"`
}

// +kubebuilder:object:generate=true
type ConfigManagementPluginList struct {
Items []ConfigManagementPlugin `json:"items"`
}

// +kubebuilder:object:generate=true
type PluginSpec struct {
Version string `json:"version,omitempty"`
Expand Down
Loading

0 comments on commit 3a7b2cb

Please sign in to comment.