Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge wooctavia and alpha to scs #81

Merged
merged 21 commits into from
May 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
47 changes: 47 additions & 0 deletions providers/openstack/scs/1-27/cluster-addon-values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
values: |
{{- define "yawol_image_id" -}}
{{- range .Cluster.spec.topology.variables -}}
{{- if eq .name "yawol_image_id" -}}
{{ .value }}
{{- end -}}
{{- end -}}
{{- end }}
{{- define "yawol_flavor_id" -}}
{{- range .Cluster.spec.topology.variables -}}
{{- if eq .name "yawol_flavor_id" -}}
{{ .value }}
{{- end -}}
{{- end -}}
{{- end }}
metrics-server:
commonLabels:
domain: "{{ .Cluster.spec.controlPlaneEndpoint.host }}"
clusterAddonVersion: "v2"
{{ range .Cluster.spec.topology.variables }}
{{- if and (eq .name "workload_loadbalancer") (eq .value "yawol") }}
yawol-controller:
enabled: true
yawolFloatingID: "{{ $.InfraCluster.status.externalNetwork.id }}"
yawolNetworkID: "{{ $.InfraCluster.status.network.id }}"
yawolAPIHost: "{{ printf "https://%s:%d" $.Cluster.spec.controlPlaneEndpoint.host $.Cluster.spec.controlPlaneEndpoint.port }}"
yawolFlavorID: {{ template "yawol_flavor_id" $}}
yawolImageID: {{ template "yawol_image_id" $}}
{{- end }}
{{- end }}

openstack-cloud-controller-manager:
cloudConfig:
loadBalancer:
{{- range .Cluster.spec.topology.variables }}
{{- if eq .name "workload_loadbalancer" }}
{{- if or (eq .value "none") (eq .value "yawol") }}
enabled: false
{{ else if eq .value "octavia-amphora" }}
enabled: true
lb-provider: amphora
{{ else if eq .value "octavia-ovn" }}
enabled: true
lb-provider: ovn
{{- end }}
{{- end }}
{{- end }}
23 changes: 23 additions & 0 deletions providers/openstack/scs/1-27/cluster-addon/.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/
18 changes: 18 additions & 0 deletions providers/openstack/scs/1-27/cluster-addon/Chart.lock
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
dependencies:
- name: metrics-server
repository: https://kubernetes-sigs.github.io/metrics-server/
version: 3.12.0
- name: cilium
repository: https://helm.cilium.io/
version: 1.15.2
- name: openstack-cloud-controller-manager
repository: https://kubernetes.github.io/cloud-provider-openstack
version: 2.27.6
- name: openstack-cinder-csi
repository: https://kubernetes.github.io/cloud-provider-openstack
version: 2.27.3
- name: yawol-controller
repository: https://stackitcloud.github.io/yawol
version: 0.21.3
digest: sha256:a9577a7d1414721ba6325511747f67dbb82f04d2b84134d92531ce2a69894a41
generated: "2024-03-27T12:49:53.970259991+01:00"
26 changes: 26 additions & 0 deletions providers/openstack/scs/1-27/cluster-addon/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
apiVersion: v2
dependencies:
- alias: metrics-server
name: metrics-server
repository: https://kubernetes-sigs.github.io/metrics-server/
version: 3.12.0
- alias: cilium
name: cilium
repository: https://helm.cilium.io/
version: 1.15.2
- alias: openstack-cloud-controller-manager
name: openstack-cloud-controller-manager
repository: https://kubernetes.github.io/cloud-provider-openstack
version: 2.27.6
- alias: openstack-cinder-csi
name: openstack-cinder-csi
repository: https://kubernetes.github.io/cloud-provider-openstack
version: 2.27.3
- alias: yawol-controller
name: yawol-controller
repository: https://stackitcloud.github.io/yawol
version: 0.21.3
condition: yawol-controller.enabled
name: openstack-wooctavia-1-27-cluster-addon
type: application
version: v3
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
51 changes: 51 additions & 0 deletions providers/openstack/scs/1-27/cluster-addon/values.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
metrics-server:
fullnameOverride: metrics-server
replicas: 1
updateStrategy:
type: RollingUpdate
rollingUpdate:
maxSurge: 0
maxUnavailable: 1

service:
labels:
kubernetes.io/cluster-service: "true"
kubernetes.io/name: "Metrics-server"

defaultArgs:
- --cert-dir=/tmp
- --kubelet-preferred-address-types=InternalIP,ExternalIP,Hostname
- --kubelet-use-node-status-port
- --metric-resolution=15s

args:
- --kubelet-insecure-tls
openstack-cloud-controller-manager:
secret:
enabled: true
name: cloud-config
create: false
nodeSelector:
node-role.kubernetes.io/control-plane: ""
tolerations:
- key: node.cloudprovider.kubernetes.io/uninitialized
value: "true"
effect: NoSchedule
- key: node-role.kubernetes.io/control-plane
effect: NoSchedule
openstack-cinder-csi:
secret:
enabled: true
name: cloud-config
create: false
nodeSelector:
node-role.kubernetes.io/control-plane: ""
tolerations:
- key: node.cloudprovider.kubernetes.io/uninitialized
value: "true"
effect: NoSchedule
- key: node-role.kubernetes.io/control-plane
effect: NoSchedule
yawol-controller:
yawolOSSecretName: cloud-config
enabled: false
23 changes: 23 additions & 0 deletions providers/openstack/scs/1-27/cluster-class/.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/
7 changes: 7 additions & 0 deletions providers/openstack/scs/1-27/cluster-class/Chart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
apiVersion: v2
description: |
This chart installs and configures:
* Openstack Wooctavia Cluster Class
name: openstack-wooctavia-1-27-cluster-class
type: application
version: v3
62 changes: 62 additions & 0 deletions providers/openstack/scs/1-27/cluster-class/templates/_helpers.tpl
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
{{/*
Expand the name of the chart.
*/}}
{{- define "cluster-class.name" -}}
{{- default .Chart.Name .Values.nameOverride | trunc 63 | trimSuffix "-" }}
{{- end }}

{{/*
Create a default fully qualified app name.
We truncate at 63 chars because some Kubernetes name fields are limited to this (by the DNS naming spec).
If release name contains chart name it will be used as a full name.
*/}}
{{- define "cluster-class.fullname" -}}
{{- if .Values.fullnameOverride }}
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" }}
{{- else }}
{{- $name := default .Chart.Name .Values.nameOverride }}
{{- if contains $name .Release.Name }}
{{- .Release.Name | trunc 63 | trimSuffix "-" }}
{{- else }}
{{- printf "%s-%s" .Release.Name $name | trunc 63 | trimSuffix "-" }}
{{- end }}
{{- end }}
{{- end }}

{{/*
Create chart name and version as used by the chart label.
*/}}
{{- define "cluster-class.chart" -}}
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
{{- end }}

{{/*
Common labels
*/}}
{{- define "cluster-class.labels" -}}
helm.sh/chart: {{ include "cluster-class.chart" . }}
{{ include "cluster-class.selectorLabels" . }}
{{- if .Chart.AppVersion }}
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
{{- end }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- end }}

{{/*
Selector labels
*/}}
{{- define "cluster-class.selectorLabels" -}}
app.kubernetes.io/name: {{ include "cluster-class.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}

{{/*
Create the name of the service account to use
*/}}
{{- define "cluster-class.serviceAccountName" -}}
{{- if .Values.serviceAccount.create }}
{{- default (include "cluster-class.fullname" .) .Values.serviceAccount.name }}
{{- else }}
{{- default "default" .Values.serviceAccount.name }}
{{- end }}
{{- end }}