Updat charts

This commit is contained in:
Nikolai Rodionov 2024-04-06 19:56:56 +02:00
parent e97a9f7f24
commit 6ae04b34f8
Signed by: allanger
GPG Key ID: 0AA46A90E25592AD
30 changed files with 840 additions and 4 deletions

View File

@ -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/

View File

@ -0,0 +1,6 @@
apiVersion: v2
name: softplayer-backend
description: A Helm chart for Kubernetes
type: application
version: 0.1.0
appVersion: "1.16.0"

View File

@ -0,0 +1,51 @@
apiVersion: networking.istio.io/v1beta1
kind: Gateway
metadata:
name: {{ include "softplayer-backend.fullname" . }}
labels:
{{- include "softplayer-backend.labels" . | nindent 4 }}
namespace: istio-system
spec:
selector:
istio: ingressgateway
servers:
- hosts:
- '*'
port:
name: grpc-web
number: 8080
protocol: HTTP2
- hosts:
- '*'
port:
name: http
number: 80
protocol: HTTP2
- hosts:
- '*'
port:
name: https
number: 443
protocol: HTTP2
---
apiVersion: networking.istio.io/v1beta1
kind: VirtualService
metadata:
name: {{ include "softplayer-backend.fullname" . }}
labels:
{{- include "softplayer-backend.labels" . | nindent 4 }}
spec:
gateways:
- istio-system/{{ include "softplayer-backend.fullname" . }}
hosts:
- "*"
http:
- match:
- uri:
prefix: /
route:
- destination:
host: {{ include "softplayer-backend.fullname" . }}
port:
number: 54321

View File

@ -0,0 +1 @@
1. Get the application URL by running these commands:

View File

@ -0,0 +1,62 @@
{{/*
Expand the name of the chart.
*/}}
{{- define "softplayer-backend.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 "softplayer-backend.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 "softplayer-backend.chart" -}}
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
{{- end }}
{{/*
Common labels
*/}}
{{- define "softplayer-backend.labels" -}}
helm.sh/chart: {{ include "softplayer-backend.chart" . }}
{{ include "softplayer-backend.selectorLabels" . }}
{{- if .Chart.AppVersion }}
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
{{- end }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- end }}
{{/*
Selector labels
*/}}
{{- define "softplayer-backend.selectorLabels" -}}
app.kubernetes.io/name: {{ include "softplayer-backend.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}
{{/*
Create the name of the service account to use
*/}}
{{- define "softplayer-backend.serviceAccountName" -}}
{{- if .Values.serviceAccount.create }}
{{- default (include "softplayer-backend.fullname" .) .Values.serviceAccount.name }}
{{- else }}
{{- default "default" .Values.serviceAccount.name }}
{{- end }}
{{- end }}

View File

@ -0,0 +1,78 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "softplayer-backend.fullname" . }}
labels:
{{- include "softplayer-backend.labels" . | nindent 4 }}
{{- with .Values.deployAnnotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- if not .Values.autoscaling.enabled }}
replicas: {{ .Values.replicaCount }}
{{- end }}
selector:
matchLabels:
{{- include "softplayer-backend.selectorLabels" . | nindent 6 }}
template:
metadata:
{{- with .Values.podAnnotations }}
annotations:
{{- toYaml . | nindent 8 }}
{{- end }}
labels:
{{- include "softplayer-backend.labels" . | nindent 8 }}
{{- with .Values.podLabels }}
{{- toYaml . | nindent 8 }}
{{- end }}
spec:
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
serviceAccountName: {{ include "softplayer-backend.serviceAccountName" . }}
securityContext:
{{- toYaml .Values.podSecurityContext | nindent 8 }}
containers:
- name: {{ .Chart.Name }}
securityContext:
{{- toYaml .Values.securityContext | nindent 12 }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
args:
- serve
- --reflection
- --smtp-host=badhouseplants.net
- --smtp-password='NCzs2fK8Gh5rAWxGte%!K54T7'
- --smtp-from=allanger@badhouseplants.net
ports:
- name: http
containerPort: {{ .Values.service.port }}
protocol: TCP
livenessProbe:
{{- toYaml .Values.livenessProbe | nindent 12 }}
readinessProbe:
{{- toYaml .Values.readinessProbe | nindent 12 }}
resources:
{{- toYaml .Values.resources | nindent 12 }}
{{- with .Values.volumeMounts }}
volumeMounts:
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.volumes }}
volumes:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}

View File

@ -0,0 +1,32 @@
{{- if .Values.autoscaling.enabled }}
apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
metadata:
name: {{ include "softplayer-backend.fullname" . }}
labels:
{{- include "softplayer-backend.labels" . | nindent 4 }}
spec:
scaleTargetRef:
apiVersion: apps/v1
kind: Deployment
name: {{ include "softplayer-backend.fullname" . }}
minReplicas: {{ .Values.autoscaling.minReplicas }}
maxReplicas: {{ .Values.autoscaling.maxReplicas }}
metrics:
{{- if .Values.autoscaling.targetCPUUtilizationPercentage }}
- type: Resource
resource:
name: cpu
target:
type: Utilization
averageUtilization: {{ .Values.autoscaling.targetCPUUtilizationPercentage }}
{{- end }}
{{- if .Values.autoscaling.targetMemoryUtilizationPercentage }}
- type: Resource
resource:
name: memory
target:
type: Utilization
averageUtilization: {{ .Values.autoscaling.targetMemoryUtilizationPercentage }}
{{- end }}
{{- end }}

View File

@ -0,0 +1,23 @@
---
apiVersion: rbac.authorization.k8s.io/v1
kind: ClusterRole
metadata:
name: {{ include "softplayer-backend.fullname" . }}
rules:
- apiGroups: ["*"]
resources: ["*"]
verbs: ["*"]
---
apiVersion: rbac.authorization.k8s.io/v1
# This cluster role binding allows anyone in the "manager" group to read secrets in any namespace.
kind: ClusterRoleBinding
metadata:
name: {{ include "softplayer-backend.fullname" . }}
subjects:
- kind: ServiceAccount
name: {{ include "softplayer-backend.serviceAccountName" . }}
namespace: {{ .Release.Namespace }}
roleRef:
kind: ClusterRole
name: {{ include "softplayer-backend.fullname" . }}
apiGroup: rbac.authorization.k8s.io

View File

@ -0,0 +1,15 @@
apiVersion: v1
kind: Service
metadata:
name: {{ include "softplayer-backend.fullname" . }}
labels:
{{- include "softplayer-backend.labels" . | nindent 4 }}
spec:
type: {{ .Values.service.type }}
ports:
- port: {{ .Values.service.port }}
targetPort: 4020
protocol: TCP
name: grpc-web
selector:
{{- include "softplayer-backend.selectorLabels" . | nindent 4 }}

View File

@ -0,0 +1,13 @@
{{- if .Values.serviceAccount.create -}}
apiVersion: v1
kind: ServiceAccount
metadata:
name: {{ include "softplayer-backend.serviceAccountName" . }}
labels:
{{- include "softplayer-backend.labels" . | nindent 4 }}
{{- with .Values.serviceAccount.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
automountServiceAccountToken: {{ .Values.serviceAccount.automount }}
{{- end }}

View File

@ -0,0 +1,15 @@
apiVersion: v1
kind: Pod
metadata:
name: "{{ include "softplayer-backend.fullname" . }}-test-connection"
labels:
{{- include "softplayer-backend.labels" . | nindent 4 }}
annotations:
"helm.sh/hook": test
spec:
containers:
- name: wget
image: busybox
command: ['wget']
args: ['{{ include "softplayer-backend.fullname" . }}:{{ .Values.service.port }}']
restartPolicy: Never

View File

@ -0,0 +1,47 @@
---
apiVersion: networking.istio.io/v1beta1
kind: VirtualService
metadata:
name: {{ include "softplayer-backend.fullname" . }}
labels:
{{- include "softplayer-backend.labels" . | nindent 4 }}
spec:
gateways:
- istio-system/badhouseplants-net
hosts:
- "softplayer-backend.badhouseplants.net"
http:
- match:
- uri:
prefix: /
route:
- destination:
host: {{ include "softplayer-backend.fullname" . }}
port:
number: 80
corsPolicy:
allowOrigin:
- "*"
allowMethods:
- POST
- GET
- OPTIONS
- PUT
- DELETE
allowHeaders:
- grpc-timeout
- content-type
- keep-alive
- user-agent
- cache-control
- content-type
- content-transfer-encoding
- custom-header-1
- x-accept-content-transfer-encoding
- x-accept-response-streaming
- x-user-agent
- x-grpc-web
maxAge: 1728s
exposeHeaders:
- grpc-status
- grpc-message

View File

@ -0,0 +1,82 @@
replicaCount: 1
image:
repository: git.badhouseplants.net/softplayer/softplayer-backend
pullPolicy: Always
tag: latest
imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""
serviceAccount:
create: true
automount: true
annotations: {}
name: ""
deployAnnotations:
keel.sh/policy: force
podLabels: {}
podSecurityContext:
fsGroup: 2000
securityContext:
capabilities:
drop:
- ALL
readOnlyRootFilesystem: true
runAsNonRoot: true
runAsUser: 1000
service:
type: ClusterIP
port: 80
resources: {}
# We usually recommend not to specify default resources and to leave this as a conscious
# choice for the user. This also increases chances charts run on environments with little
# resources, such as Minikube. If you do want to specify resources, uncomment the following
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
# limits:
# cpu: 100m
# memory: 128Mi
# requests:
# cpu: 100m
# memory: 128Mi
## livenessProbe:
## httpGet:
## path: /
## port: http
## readinessProbe:
## httpGet:
## path: /
## port: http
autoscaling:
enabled: false
minReplicas: 1
maxReplicas: 100
targetCPUUtilizationPercentage: 80
# targetMemoryUtilizationPercentage: 80
# Additional volumes on the output Deployment definition.
volumes: []
# - name: foo
# secret:
# secretName: mysecret
# optional: false
# Additional volumeMounts on the output Deployment definition.
volumeMounts: []
# - name: foo
# mountPath: "/etc/foo"
# readOnly: true
nodeSelector: {}
tolerations: []
affinity: {}

View File

@ -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/

View File

@ -0,0 +1,6 @@
apiVersion: v2
name: softplayer-web
description: A Helm chart for Kubernetes
type: application
version: 0.1.0
appVersion: "1.16.0"

View File

@ -0,0 +1,51 @@
apiVersion: networking.istio.io/v1beta1
kind: Gateway
metadata:
name: {{ include "softplayer-web.fullname" . }}
labels:
{{- include "softplayer-web.labels" . | nindent 4 }}
namespace: istio-system
spec:
selector:
istio: ingressgateway
servers:
- hosts:
- '*'
port:
name: grpc-web
number: 8080
protocol: HTTP2
- hosts:
- '*'
port:
name: http
number: 80
protocol: HTTP2
- hosts:
- '*'
port:
name: https
number: 443
protocol: HTTP2
---
apiVersion: networking.istio.io/v1beta1
kind: VirtualService
metadata:
name: {{ include "softplayer-web.fullname" . }}
labels:
{{- include "softplayer-web.labels" . | nindent 4 }}
spec:
gateways:
- istio-system/{{ include "softplayer-web.fullname" . }}
hosts:
- "*"
http:
- match:
- uri:
prefix: /
route:
- destination:
host: {{ include "softplayer-web.fullname" . }}
port:
number: 54321

View File

@ -0,0 +1 @@
1. Get the application URL by running these commands:

View File

@ -0,0 +1,62 @@
{{/*
Expand the name of the chart.
*/}}
{{- define "softplayer-web.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 "softplayer-web.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 "softplayer-web.chart" -}}
{{- printf "%s-%s" .Chart.Name .Chart.Version | replace "+" "_" | trunc 63 | trimSuffix "-" }}
{{- end }}
{{/*
Common labels
*/}}
{{- define "softplayer-web.labels" -}}
helm.sh/chart: {{ include "softplayer-web.chart" . }}
{{ include "softplayer-web.selectorLabels" . }}
{{- if .Chart.AppVersion }}
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
{{- end }}
app.kubernetes.io/managed-by: {{ .Release.Service }}
{{- end }}
{{/*
Selector labels
*/}}
{{- define "softplayer-web.selectorLabels" -}}
app.kubernetes.io/name: {{ include "softplayer-web.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- end }}
{{/*
Create the name of the service account to use
*/}}
{{- define "softplayer-web.serviceAccountName" -}}
{{- if .Values.serviceAccount.create }}
{{- default (include "softplayer-web.fullname" .) .Values.serviceAccount.name }}
{{- else }}
{{- default "default" .Values.serviceAccount.name }}
{{- end }}
{{- end }}

View File

@ -0,0 +1,76 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "softplayer-web.fullname" . }}
labels:
{{- include "softplayer-web.labels" . | nindent 4 }}
{{- with .Values.deployAnnotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
{{- if not .Values.autoscaling.enabled }}
replicas: {{ .Values.replicaCount }}
{{- end }}
selector:
matchLabels:
{{- include "softplayer-web.selectorLabels" . | nindent 6 }}
template:
metadata:
{{- with .Values.podAnnotations }}
annotations:
{{- toYaml . | nindent 8 }}
{{- end }}
labels:
{{- include "softplayer-web.labels" . | nindent 8 }}
{{- with .Values.podLabels }}
{{- toYaml . | nindent 8 }}
{{- end }}
spec:
{{- with .Values.imagePullSecrets }}
imagePullSecrets:
{{- toYaml . | nindent 8 }}
{{- end }}
securityContext:
{{- toYaml .Values.podSecurityContext | nindent 8 }}
containers:
- name: {{ .Chart.Name }}
securityContext:
{{- toYaml .Values.securityContext | nindent 12 }}
image: "{{ .Values.image.repository }}:{{ .Values.image.tag | default .Chart.AppVersion }}"
imagePullPolicy: {{ .Values.image.pullPolicy }}
ports:
- name: http
containerPort: {{ .Values.service.port }}
protocol: TCP
livenessProbe:
{{- toYaml .Values.livenessProbe | nindent 12 }}
readinessProbe:
{{- toYaml .Values.readinessProbe | nindent 12 }}
resources:
{{- toYaml .Values.resources | nindent 12 }}
{{- with .Values.volumeMounts }}
volumeMounts:
- mountPath: /var/cache/nginx
name: cache-volume
{{- toYaml . | nindent 12 }}
{{- end }}
{{- with .Values.volumes }}
volumes:
{{- toYaml . | nindent 8 }}
- name: cache-volume
emptyDir:
sizeLimit: 500Mi
{{- end }}
{{- with .Values.nodeSelector }}
nodeSelector:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.affinity }}
affinity:
{{- toYaml . | nindent 8 }}
{{- end }}
{{- with .Values.tolerations }}
tolerations:
{{- toYaml . | nindent 8 }}
{{- end }}

View File

@ -0,0 +1,15 @@
apiVersion: v1
kind: Service
metadata:
name: {{ include "softplayer-web.fullname" . }}
labels:
{{- include "softplayer-web.labels" . | nindent 4 }}
spec:
type: {{ .Values.service.type }}
ports:
- port: {{ .Values.service.port }}
targetPort: 80
protocol: TCP
name: http
selector:
{{- include "softplayer-web.selectorLabels" . | nindent 4 }}

View File

@ -0,0 +1,15 @@
apiVersion: v1
kind: Pod
metadata:
name: "{{ include "softplayer-web.fullname" . }}-test-connection"
labels:
{{- include "softplayer-web.labels" . | nindent 4 }}
annotations:
"helm.sh/hook": test
spec:
containers:
- name: wget
image: busybox
command: ['wget']
args: ['{{ include "softplayer-web.fullname" . }}:{{ .Values.service.port }}']
restartPolicy: Never

View File

@ -0,0 +1,21 @@
---
apiVersion: networking.istio.io/v1beta1
kind: VirtualService
metadata:
name: {{ include "softplayer-web.fullname" . }}
labels:
{{- include "softplayer-web.labels" . | nindent 4 }}
spec:
gateways:
- istio-system/badhouseplants-net
hosts:
- "softplayer-web.badhouseplants.net"
http:
- match:
- uri:
prefix: /
route:
- destination:
host: {{ include "softplayer-web.fullname" . }}
port:
number: 80

View File

@ -0,0 +1,72 @@
replicaCount: 1
image:
repository: git.badhouseplants.net/softplayer/softplayer-web
pullPolicy: Always
tag: 45a52d541049ac142c7144ab1da5de8c79be62ce
imagePullSecrets: []
nameOverride: ""
fullnameOverride: ""
serviceAccount:
create: true
automount: true
annotations: {}
name: ""
deployAnnotations:
keel.sh/policy: force
podLabels: {}
service:
type: ClusterIP
port: 80
resources: {}
# We usually recommend not to specify default resources and to leave this as a conscious
# choice for the user. This also increases chances charts run on environments with little
# resources, such as Minikube. If you do want to specify resources, uncomment the following
# lines, adjust them as necessary, and remove the curly braces after 'resources:'.
# limits:
# cpu: 100m
# memory: 128Mi
# requests:
# cpu: 100m
# memory: 128Mi
## livenessProbe:
## httpGet:
## path: /
## port: http
## readinessProbe:
## httpGet:
## path: /
## port: http
autoscaling:
enabled: false
minReplicas: 1
maxReplicas: 100
targetCPUUtilizationPercentage: 80
# targetMemoryUtilizationPercentage: 80
# Additional volumes on the output Deployment definition.
volumes: []
# - name: foo
# secret:
# secretName: mysecret
# optional: false
# Additional volumeMounts on the output Deployment definition.
volumeMounts: []
# - name: foo
# mountPath: "/etc/foo"
# readOnly: true
nodeSelector: {}
tolerations: []
affinity: {}

View File

@ -8,7 +8,7 @@ metadata:
{{- include "tekton-pipelines.labels" . | nindent 4 }} {{- include "tekton-pipelines.labels" . | nindent 4 }}
rules: rules:
- apiGroups: [""] - apiGroups: [""]
resources: ["secrets"] resources: ["secrets", "configmaps"]
verbs: ["*"] verbs: ["*"]
--- ---
apiVersion: v1 apiVersion: v1

View File

@ -31,6 +31,14 @@ spec:
| base64 -d > /tmp/outputs/inventory.yaml | base64 -d > /tmp/outputs/inventory.yaml
chmod 0600 /tmp/outputs/ssh_key chmod 0600 /tmp/outputs/ssh_key
chmod 0600 /tmp/outputs/ssh_key.pub chmod 0600 /tmp/outputs/ssh_key.pub
- name: annonate-an-env-cm
image: alpine/k8s:1.29.2
script: |-
#!/bin/sh
kubectl annotate --overwrite configmap \
"$(params.environment)" \
--namespace "$(params.namespace)" \
"softplayer.net/status=servers-configuration"
- name: prepare-servers - name: prepare-servers
image: git.badhouseplants.net/softplayer/softplayer-coskgne:latest image: git.badhouseplants.net/softplayer/softplayer-coskgne:latest
env: env:

View File

@ -35,10 +35,10 @@ spec:
#!/bin/sh #!/bin/sh
kubectl delete secret \ kubectl delete secret \
"$(params.environment)-inventory" \ "$(params.environment)-inventory" \
--namespace "$(params.namespace)" --namespace "$(params.namespace)" || true
kubectl delete secret \ kubectl delete secret \
"$(params.environment)-ssh" \ "$(params.environment)-ssh" \
--namespace "$(params.namespace)" --namespace "$(params.namespace)" || true
kubectl delete secret \ kubectl delete secret \
"$(params.environment)-config" \ "$(params.environment)-config" \
--namespace "$(params.namespace)" --namespace "$(params.namespace)" || true

View File

@ -22,6 +22,14 @@ spec:
| yq '.data.kubeconfig' \ | yq '.data.kubeconfig' \
| base64 -d > /tmp/outputs/config | base64 -d > /tmp/outputs/config
chmod 0600 /tmp/outputs/config chmod 0600 /tmp/outputs/config
- name: annonate-an-env-cm
image: alpine/k8s:1.29.2
script: |-
#!/bin/sh
kubectl annotate --overwrite configmap \
"$(params.environment)" \
--namespace "$(params.namespace)" \
"softplayer.net/status=installing-dependencies"
- name: deploy-helmfile - name: deploy-helmfile
image: ghcr.io/helmfile/helmfile:v0.163.1 image: ghcr.io/helmfile/helmfile:v0.163.1
env: env:
@ -32,6 +40,14 @@ spec:
mkdir -p /src mkdir -p /src
git clone https://git.badhouseplants.net/softplayer/softplayer-helmfile.git /src/helmfile git clone https://git.badhouseplants.net/softplayer/softplayer-helmfile.git /src/helmfile
cd /src/helmfile/workload && helmfile sync cd /src/helmfile/workload && helmfile sync
- name: annonate-an-env-cm
image: alpine/k8s:1.29.2
script: |-
#!/bin/sh
kubectl annotate --overwrite configmap \
"$(params.environment)" \
--namespace "$(params.namespace)" \
"softplayer.net/status=ready"
workspaces: workspaces:
- name: outputs - name: outputs
description: A folder to store outputs description: A folder to store outputs

View File

@ -22,6 +22,14 @@ spec:
| yq '.data."ssh_key.pub"' \ | yq '.data."ssh_key.pub"' \
| base64 -d > /tmp/outputs/ssh_key.pub | base64 -d > /tmp/outputs/ssh_key.pub
chmod 0600 /tmp/outputs/ssh_key.pub chmod 0600 /tmp/outputs/ssh_key.pub
- name: annonate-an-env-cm
image: alpine/k8s:1.29.2
script: |-
#!/bin/sh
kubectl annotate --overwrite configmap \
"$(params.environment)" \
--namespace "$(params.namespace)" \
"softplayer.net/status=infra-bootstrapping"
- name: create-hetzner-infra - name: create-hetzner-infra
image: git.badhouseplants.net/softplayer/softplayer-coskgne:latest image: git.badhouseplants.net/softplayer/softplayer-coskgne:latest
env: env:

View File

@ -87,6 +87,8 @@ releases:
chart: zot/local-path-provisioner chart: zot/local-path-provisioner
namespace: kube-system namespace: kube-system
version: 0.0.25-dev version: 0.0.25-dev
values:
- ./values/local-path.yaml
needs: needs:
- kube-system/namespaces - kube-system/namespaces
- kube-system/coredns - kube-system/coredns
@ -100,6 +102,7 @@ releases:
- kube-system/namespaces - kube-system/namespaces
- kube-system/coredns - kube-system/coredns
- kube-system/cilium - kube-system/cilium
- name: istio-ingressgateway - name: istio-ingressgateway
chart: istio/gateway chart: istio/gateway
namespace: istio-system namespace: istio-system
@ -107,8 +110,10 @@ releases:
- kube-system/namespaces - kube-system/namespaces
- kube-system/coredns - kube-system/coredns
- kube-system/cilium - kube-system/cilium
- istio-system/istio-base
values: values:
- ./values/values.istio-ingressgateway.yaml - ./values/values.istio-ingressgateway.yaml
- name: istiod - name: istiod
chart: istio/istiod chart: istio/istiod
namespace: istio-system namespace: istio-system
@ -118,3 +123,9 @@ releases:
- kube-system/cilium - kube-system/cilium
values: values:
- ./values/values.istiod.yaml - ./values/values.istiod.yaml
- name: softplayer-backend
chart: ../charts/softplayer-backend
namespace: softplayer-backend
needs:
- istio-system/istio-ingressgateway

View File

@ -0,0 +1,3 @@
storageClass:
create: true
defaultClass: true