Skip to content

Commit

Permalink
Merge branch 'main' into adopted-cluster
Browse files Browse the repository at this point in the history
  • Loading branch information
eromanova authored Dec 24, 2024
2 parents f96ce95 + 6209d28 commit c6d56f0
Show file tree
Hide file tree
Showing 13 changed files with 138 additions and 7 deletions.
2 changes: 1 addition & 1 deletion CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -1 +1 @@
* @Kshatrix @eromanova @a13x5
* @Kshatrix @eromanova @a13x5 @zerospiel
2 changes: 2 additions & 0 deletions api/v1alpha1/common.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,8 @@ const (
ProviderAzureName = "cluster-api-provider-azure"
// Provider vSphere
ProviderVSphereName = "cluster-api-provider-vsphere"
// Provider OpenStack
ProviderOpenStackName = "cluster-api-provider-openstack"
// Provider K0smotron
ProviderK0smotronName = "k0smotron"
// Provider Sveltos
Expand Down
1 change: 1 addition & 0 deletions api/v1alpha1/management_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,7 @@ func GetDefaultProviders() []Provider {
{Name: ProviderAWSName},
{Name: ProviderAzureName},
{Name: ProviderVSphereName},
{Name: ProviderOpenStackName},
{Name: ProviderSveltosName},
}
}
Expand Down
4 changes: 2 additions & 2 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ require (
k8s.io/apimachinery v0.31.3
k8s.io/client-go v0.31.3
k8s.io/utils v0.0.0-20241104163129-6fe5fd82f078
sigs.k8s.io/cluster-api v1.9.1
sigs.k8s.io/cluster-api v1.9.3
sigs.k8s.io/cluster-api-operator v0.14.0
sigs.k8s.io/cluster-api-provider-azure v1.17.2
sigs.k8s.io/cluster-api-provider-vsphere v1.12.0
Expand Down Expand Up @@ -173,7 +173,7 @@ require (
golang.org/x/crypto v0.31.0 // indirect
golang.org/x/exp v0.0.0-20241004190924-225e2abe05e6 // indirect
golang.org/x/mod v0.22.0 // indirect
golang.org/x/net v0.32.0 // indirect
golang.org/x/net v0.33.0 // indirect
golang.org/x/oauth2 v0.24.0 // indirect
golang.org/x/sync v0.10.0 // indirect
golang.org/x/sys v0.28.0 // indirect
Expand Down
8 changes: 4 additions & 4 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -555,8 +555,8 @@ golang.org/x/net v0.7.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs=
golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg=
golang.org/x/net v0.21.0/go.mod h1:bIjVDfnllIU7BJ2DNgfnXvpSvtn8VRwhlsaeUTyUS44=
golang.org/x/net v0.22.0/go.mod h1:JKghWKKOSdJwpW2GEx0Ja7fmaKnMsbu+MWVZTokSYmg=
golang.org/x/net v0.32.0 h1:ZqPmj8Kzc+Y6e0+skZsuACbx+wzMgo5MQsJh9Qd6aYI=
golang.org/x/net v0.32.0/go.mod h1:CwU0IoeOlnQQWJ6ioyFrfRuomB8GKF6KbYXZVyeXNfs=
golang.org/x/net v0.33.0 h1:74SYHlV8BIgHIFC/LrYkOGIwL19eTYXQ5wc6TBuO36I=
golang.org/x/net v0.33.0/go.mod h1:HXLR5J+9DxmrqMwG9qjGCxZ+zKXxBru04zlTvWlWuN4=
golang.org/x/oauth2 v0.24.0 h1:KTBBxWqUa0ykRPLtV69rRto9TLXcqYkeswu48x/gvNE=
golang.org/x/oauth2 v0.24.0/go.mod h1:XYTD2NtWslqkgxebSiOHnXEap4TF09sJSc7H1sXbhtI=
golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM=
Expand Down Expand Up @@ -678,8 +678,8 @@ oras.land/oras-go v1.2.6 h1:z8cmxQXBU8yZ4mkytWqXfo6tZcamPwjsuxYU81xJ8Lk=
oras.land/oras-go v1.2.6/go.mod h1:OVPc1PegSEe/K8YiLfosrlqlqTN9PUyFvOw5Y9gwrT8=
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.30.3 h1:2770sDpzrjjsAtVhSeUFseziht227YAWYHLGNM8QPwY=
sigs.k8s.io/apiserver-network-proxy/konnectivity-client v0.30.3/go.mod h1:Ve9uj1L+deCXFrPOk1LpFXqTg7LCFzFso6PA48q/XZw=
sigs.k8s.io/cluster-api v1.9.1 h1:s2YUB66XceK+EQ3Uq8Mq/N9TgqRU4TQUMsaQYXOIWlU=
sigs.k8s.io/cluster-api v1.9.1/go.mod h1:pkFqVPq0ELlJgyDjgqpb4MU1XnWEi98B2q3DbEjC4ww=
sigs.k8s.io/cluster-api v1.9.3 h1:lKWbrXzyNmJh++IcX54ZbAmnO7tZ2wKgds7WvskpiXY=
sigs.k8s.io/cluster-api v1.9.3/go.mod h1:5iojv38PSvOd4cxqu08Un5TQmy2yBkd3+0U7R/e+msk=
sigs.k8s.io/cluster-api-operator v0.14.0 h1:0QgO6+XGrNNJnNHKBwvQD5v6w+EaH3Z0RL1nL3wpjA4=
sigs.k8s.io/cluster-api-operator v0.14.0/go.mod h1:euShpVN6HyxXas28HkrYxhCPVDW1UV6ljbRBAeCxp8Y=
sigs.k8s.io/cluster-api-provider-azure v1.17.2 h1:uS9ggE/bryI0hiOWHBa56nYHkWmsPZW3bzYeAddL4vM=
Expand Down
23 changes: 23 additions & 0 deletions templates/provider/cluster-api-provider-openstack/.helmignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# Patterns to ignore when building packages.
# This supports shell glob matching, relative path matching, and
# negation (prefixed with !). Only one pattern per line.
.DS_Store
# Common VCS dirs
.git/
.gitignore
.bzr/
.bzrignore
.hg/
.hgignore
.svn/
# Common backup files
*.swp
*.bak
*.tmp
*.orig
*~
# Various IDEs
.project
.idea/
*.tmproj
.vscode/
24 changes: 24 additions & 0 deletions templates/provider/cluster-api-provider-openstack/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
apiVersion: v2
name: cluster-api-provider-openstack
description: A Helm chart for Cluster API provider OpenStack
# A chart can be either an 'application' or a 'library' chart.
#
# Application charts are a collection of templates that can be packaged into versioned archives
# to be deployed.
#
# Library charts provide useful utilities or functions for the chart developer. They're included as
# a dependency of application charts to inject those utilities and functions into the rendering
# pipeline. Library charts do not define any templates and therefore cannot be deployed.
type: application
# This is the chart version. This version number should be incremented each time you make changes
# to the chart and its templates, including the app version.
# Versions are expected to follow Semantic Versioning (https://semver.org/)
version: 0.0.1
# This is the version number of the application being deployed. This version number should be
# incremented each time you make changes to the application. Versions are not expected to
# follow Semantic Versioning. They should reflect the version the application is using.
# It is recommended to use it with quotes.
appVersion: "v0.11.3"
annotations:
cluster.x-k8s.io/provider: infrastructure-openstack
cluster.x-k8s.io/v1beta1: v1beta1
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
apiVersion: operator.cluster.x-k8s.io/v1alpha2
kind: InfrastructureProvider
metadata:
name: openstack
spec:
version: v0.11.3
{{- if .Values.configSecret.name }}
configSecret:
name: {{ .Values.configSecret.name }}
namespace: {{ .Values.configSecret.namespace | default .Release.Namespace | trunc 63 }}
{{- end }}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{{- if and .Values.configSecret.create .Values.configSecret.name }}
apiVersion: v1
kind: Secret
metadata:
name: {{ .Values.configSecret.name }}
namespace: {{ .Values.configSecret.namespace | default .Release.Namespace | trunc 63 }}
stringData:
{{ toYaml .Values.config | indent 2 }}
{{- end }}
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"description": "Schema for configuration secret settings used in the OpenStack deployment.",
"type": "object",
"required": [
"configSecret"
],
"properties": {
"configSecret": {
"type": "object",
"description": "Settings for the OpenStack configuration secret.",
"required": [
"create",
"name"
],
"properties": {
"create": {
"type": "boolean",
"description": "Indicates whether a new secret should be created."
},
"name": {
"type": "string",
"description": "The name of the OpenStack configuration secret."
},
"namespace": {
"type": "string",
"description": "The namespace where the OpenStack configuration secret will be created or referenced."
}
}
},
"config": {
"type": "object",
"additionalProperties": {
"type": "string"
}
}
}
}
6 changes: 6 additions & 0 deletions templates/provider/cluster-api-provider-openstack/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
configSecret:
create: false
name: ""
namespace: ""

config: {}
2 changes: 2 additions & 0 deletions templates/provider/hmc-templates/files/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,5 +19,7 @@ spec:
template: cluster-api-provider-vsphere-0-0-4
- name: cluster-api-provider-aws
template: cluster-api-provider-aws-0-0-4
- name: cluster-api-provider-openstack
template: cluster-api-provider-openstack-0-0-1
- name: projectsveltos
template: projectsveltos-0-44-0
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
apiVersion: hmc.mirantis.com/v1alpha1
kind: ProviderTemplate
metadata:
name: cluster-api-provider-openstack-0-0-1
annotations:
helm.sh/resource-policy: keep
spec:
helm:
chartSpec:
chart: cluster-api-provider-openstack
version: 0.0.1
interval: 10m0s
sourceRef:
kind: HelmRepository
name: hmc-templates

0 comments on commit c6d56f0

Please sign in to comment.