Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
84 commits
Select commit Hold shift + click to select a range
fb04c01
feat: replace install job by apl-operator
CasLubbers Sep 5, 2025
34738ea
feat: fix test
CasLubbers Sep 5, 2025
8d1549b
Merge remote-tracking branch 'origin/main' into APL-940
svcAPLBot Sep 8, 2025
a9d855f
fix: set correct command
CasLubbers Sep 8, 2025
e60bf3a
fix: set SOPS_AGE_KEY
CasLubbers Sep 8, 2025
87309eb
Merge remote-tracking branch 'origin/main' into APL-940
svcAPLBot Sep 8, 2025
eff416f
fix: chart
CasLubbers Sep 8, 2025
8d217c6
fix: chart
CasLubbers Sep 8, 2025
d1c4aa6
fix: chart
CasLubbers Sep 8, 2025
8ec4f1d
fix: chart
CasLubbers Sep 8, 2025
25aefe5
fix: chart
CasLubbers Sep 8, 2025
f6fec71
fix: run post-install steps async
CasLubbers Sep 9, 2025
2af0e5d
fix: run post-install steps async
CasLubbers Sep 9, 2025
4a8d1e7
Merge remote-tracking branch 'origin/main' into APL-940
svcAPLBot Sep 9, 2025
ce9c1d7
Merge remote-tracking branch 'origin/main' into APL-940
svcAPLBot Sep 9, 2025
a635a0a
fix: getting git credentials
CasLubbers Sep 9, 2025
b292190
fix: dont clone repository
CasLubbers Sep 9, 2025
9931960
fix: updating configmap
CasLubbers Sep 9, 2025
538d7ca
test: see repourl
CasLubbers Sep 9, 2025
8548d54
test: see repourl
CasLubbers Sep 9, 2025
2299feb
test: add logging
CasLubbers Sep 9, 2025
f3905a0
feat: keep directory on restart
CasLubbers Sep 9, 2025
edbaba3
Merge remote-tracking branch 'origin/main' into APL-940
svcAPLBot Sep 9, 2025
268cad4
fix: chart
CasLubbers Sep 9, 2025
9daa101
fix: chart
CasLubbers Sep 9, 2025
b60d66a
fix: chart
CasLubbers Sep 9, 2025
90a5a5d
Merge remote-tracking branch 'origin/main' into APL-940
svcAPLBot Sep 9, 2025
93e979b
fix: create if not exist secret
CasLubbers Sep 10, 2025
210f806
Merge remote-tracking branch 'origin/main' into APL-940
svcAPLBot Sep 11, 2025
963dbd0
Merge remote-tracking branch 'origin/main' into APL-940
svcAPLBot Sep 12, 2025
3290b50
Merge remote-tracking branch 'origin/main' into APL-940
svcAPLBot Sep 12, 2025
edb54fd
Merge remote-tracking branch 'origin/main' into APL-940
CasLubbers Nov 11, 2025
02ffaca
feat: improve install setup
CasLubbers Nov 11, 2025
115fa43
feat: adjust welcome configmap and fix tests
CasLubbers Nov 11, 2025
9b24ea1
feat: handle git credentials better
CasLubbers Nov 11, 2025
f67fc48
feat: remove duplicate code execution
CasLubbers Nov 11, 2025
30699f1
feat: reuse values for helmfile
CasLubbers Nov 12, 2025
b4058d2
fix: tests
CasLubbers Nov 12, 2025
f1a801e
fix: tests
CasLubbers Nov 12, 2025
bfae1c6
fix: helmfile
CasLubbers Nov 12, 2025
d57024e
feat: refactor install
CasLubbers Nov 12, 2025
6e7dcfd
feat: add tests for installer
CasLubbers Nov 12, 2025
017109f
Merge branch 'main' into APL-940
CasLubbers Nov 12, 2025
7805cb0
fix: removed test file
CasLubbers Nov 12, 2025
781d6d6
Merge branch 'main' into APL-940
svcAPLBot Nov 12, 2025
e23ddbd
Merge branch 'main' into APL-940
svcAPLBot Nov 12, 2025
edb4e3e
fix: remove log line
CasLubbers Nov 13, 2025
b688c1d
feat: add execution flow
CasLubbers Nov 13, 2025
2ea0c76
Merge branch 'main' into APL-940
svcAPLBot Nov 13, 2025
5b7755e
Merge branch 'main' into APL-940
svcAPLBot Nov 13, 2025
89d87b4
Merge branch 'main' into APL-940
svcAPLBot Nov 13, 2025
c3c36b1
Merge branch 'main' into APL-940
svcAPLBot Nov 13, 2025
c3b490f
fix: review comments
CasLubbers Nov 14, 2025
96c9e73
fix: update selector labels to use static values
CasLubbers Nov 14, 2025
660653f
feat: create git credentials and lower verbose logging
CasLubbers Nov 14, 2025
e11a88b
fix: remove verbose logging
CasLubbers Nov 14, 2025
a7d894f
fix: tests
CasLubbers Nov 17, 2025
f9e34d4
fix: tests
CasLubbers Nov 17, 2025
d994cd6
fix: add back creation of sops-secrets file
CasLubbers Nov 17, 2025
d0b9629
fix: logging
CasLubbers Nov 17, 2025
61af3af
fix: logging
CasLubbers Nov 17, 2025
441de18
fix: check correct origin
CasLubbers Nov 17, 2025
33b616c
fix: add logging
CasLubbers Nov 17, 2025
55fd427
fix: add logging
CasLubbers Nov 17, 2025
6f9f000
fix: remove wait for commits
CasLubbers Nov 17, 2025
dd9fca4
fix: set age key early
CasLubbers Nov 17, 2025
72673cf
fix: getStoredClusterSecrets
CasLubbers Nov 18, 2025
1ad9609
fix: getStoredClusterSecrets
CasLubbers Nov 18, 2025
c827946
fix: cleanup
CasLubbers Nov 18, 2025
1b84945
fix: cleanup
CasLubbers Nov 18, 2025
0ea1ae9
fix: logging
CasLubbers Nov 18, 2025
e0a34cd
fix: logging
CasLubbers Nov 18, 2025
826bb73
fix: add waitfor crd
CasLubbers Nov 18, 2025
7ba6285
fix: tests
CasLubbers Nov 18, 2025
223c5f9
fix: tests
CasLubbers Nov 18, 2025
1a60358
feat: update logging
CasLubbers Nov 18, 2025
4305ce7
Merge remote-tracking branch 'origin/main' into APL-940
CasLubbers Nov 18, 2025
ce7af5f
Merge branch 'main' into APL-940
CasLubbers Nov 18, 2025
998a3de
Merge branch 'main' into APL-940
svcAPLBot Nov 18, 2025
c366089
Merge branch 'main' into APL-940
svcAPLBot Nov 18, 2025
459cd6f
fix: remove gitea and sops secrets from chart
CasLubbers Nov 20, 2025
79c6575
Merge branch 'main' into APL-940
svcAPLBot Nov 20, 2025
1a29321
fix: add back secrets
CasLubbers Nov 20, 2025
dbc8e1e
Merge remote-tracking branch 'origin/main' into APL-940
CasLubbers Nov 20, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions chart/apl/Chart.yaml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
apiVersion: v2
name: apl
name: apl-operator
description: A Helm chart for installing APL in Kubernetes
home: https://techdocs.akamai.com/app-platform/docs/welcome
type: application
version: 0.0.0-chart-version
appVersion: APP_VERSION_PLACEHOLDER
appVersion: "main"
keywords:
- linode
- lke
Expand Down
15 changes: 15 additions & 0 deletions chart/apl/templates/00-namespace.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
apiVersion: v1
kind: Namespace
metadata:
name: apl-operator
labels:
kubernetes.io/metadata.name: apl-operator
name: apl-operator
---
apiVersion: v1
kind: Namespace
metadata:
name: otomi
labels:
kubernetes.io/metadata.name: otomi
name: otomi
2 changes: 1 addition & 1 deletion chart/apl/templates/NOTES.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
The APL installer was successfully deployed on the cluster.

Please inspect the output of the installer job ({{ .Release.Namespace }}/{{ include "apl.fullname" . }}) for any feedback or errors.
Please inspect the output of the installer job ({{ .Release.Namespace }}/{{ include "apl-operator.fullname" . }}) for any feedback or errors.

Also visit https://apl-docs.net for further instructions and reference documentation.
47 changes: 26 additions & 21 deletions chart/apl/templates/_helpers.tpl
Original file line number Diff line number Diff line change
@@ -1,41 +1,35 @@
{{/*
Expand the name of the chart.
*/}}
{{- define "apl.name" -}}
{{- define "apl-operator.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.
Always returns "apl-operator" to ensure consistent naming.
*/}}
{{- define "apl.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 }}
{{- define "apl-operator.fullname" -}}
{{- if .Values.fullnameOverride -}}
{{- .Values.fullnameOverride | trunc 63 | trimSuffix "-" -}}
{{- else -}}
apl-operator
{{- end -}}
{{- end }}

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

{{/*
Common labels
*/}}
{{- define "apl.labels" -}}
helm.sh/chart: {{ include "apl.chart" . }}
{{ include "apl.selectorLabels" . }}
{{- define "apl-operator.labels" -}}
helm.sh/chart: {{ include "apl-operator.chart" . }}
{{ include "apl-operator.selectorLabels" . }}
{{- if .Chart.AppVersion }}
app.kubernetes.io/version: {{ .Chart.AppVersion | quote }}
{{- end }}
Expand All @@ -45,8 +39,19 @@ app.kubernetes.io/managed-by: {{ .Release.Service }}
{{/*
Selector labels
*/}}
{{- define "apl.selectorLabels" -}}
app.kubernetes.io/name: {{ include "apl.name" . }}
app.kubernetes.io/instance: {{ .Release.Name }}
{{- define "apl-operator.selectorLabels" -}}
app.kubernetes.io/name: apl-operator
app.kubernetes.io/instance: apl-operator
{{- end }}

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

9 changes: 9 additions & 0 deletions chart/apl/templates/conf.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: git-config
namespace: apl-operator
data:
.gitconfig: |
[safe]
directory = *
128 changes: 128 additions & 0 deletions chart/apl/templates/deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,128 @@
{{- $kms := .Values.kms | default dict }}
{{- $imageName := .Values.imageName | default "linode/apl-core" }}
{{- $version := .Values.otomi.version | default .Chart.AppVersion }}
{{- $useORCS := .Values.otomi.useORCS | default "true"}}
apiVersion: apps/v1
kind: Deployment
metadata:
name: {{ include "apl-operator.fullname" . }}
namespace: apl-operator
labels: {{- include "apl-operator.labels" . | nindent 4 }}
spec:
replicas: 1
selector:
matchLabels: {{- include "apl-operator.selectorLabels" . | nindent 6 }}
template:
metadata:
{{- with .Values.podAnnotations }}
annotations: {{- toYaml . | nindent 8 }}
{{- end }}
labels: {{- include "apl-operator.selectorLabels" . | nindent 8 }}
spec:
dnsConfig:
nameservers:
- 8.8.8.8
- 8.8.4.4
restartPolicy: Always
serviceAccountName: {{ include "apl-operator.serviceAccountName" . }}
securityContext:
runAsNonRoot: true
runAsUser: 999
runAsGroup: 999
fsGroup: 3000
seccompProfile:
type: RuntimeDefault
containers:
- name: apl-operator
{{- if $useORCS }}
image: "mirror.registry.linodelke.net/docker/{{ $imageName }}:{{ $version }}"
{{- else }}
image: "{{ $imageName }}:{{ $version }}"
{{- end }}
imagePullPolicy: {{ ternary "IfNotPresent" "Always" (regexMatch "^v\\d" $version) }}
securityContext:
allowPrivilegeEscalation: false
capabilities:
drop:
- ALL
readOnlyRootFilesystem: true
runAsNonRoot: true
runAsUser: 1001
resources:
limits:
cpu: '2'
memory: '2Gi'
requests:
cpu: '1'
memory: '1Gi'
workingDir: /home/app/stack
command:
- node
- dist/src/operator/main.js
env:
- name: VERBOSITY
value: '1'
- name: ENV_DIR
value: /home/app/stack/env
- name: VALUES_INPUT
value: /secret/values.yaml
# Git configuration for operator (will be set after installation)
- name: GIT_ORG
value: {{ .Values.operator.gitOrg | default "apl" | quote }}
- name: GIT_REPO
value: {{ .Values.operator.gitRepo | default "values" | quote }}
- name: POLL_INTERVAL_MS
value: {{ .Values.operator.pollIntervalMs | default "30000" | quote }}
- name: RECONCILE_INTERVAL_MS
value: {{ .Values.operator.reconcileIntervalMs | default "300000" | quote }}
{{- if hasKey $kms "sops" }}
envFrom:
- secretRef:
name: apl-sops-secrets
- secretRef:
name: gitea-credentials
{{- end }}
volumeMounts:
- name: otomi-values
mountPath: /home/app/stack/env
- name: values-secret
mountPath: /secret
- name: tmp
mountPath: /tmp
- name: git-config
mountPath: /home/app/.gitconfig
subPath: .gitconfig
livenessProbe:
exec:
command: ["/bin/sh", "-c", "pgrep -f 'apl-operator' > /dev/null"]
initialDelaySeconds: 60
periodSeconds: 30
timeoutSeconds: 10
failureThreshold: 3
readinessProbe:
exec:
command: ["/bin/sh", "-c", "pgrep -f 'apl-operator' > /dev/null"]
initialDelaySeconds: 30
periodSeconds: 10
timeoutSeconds: 5
failureThreshold: 3
volumes:
- name: values-secret
secret:
secretName: {{ .Release.Name }}-values
- name: otomi-values
emptyDir: {}
- name: tmp
emptyDir: {}
- name: git-config
configMap:
name: git-config
items:
- key: .gitconfig
path: .gitconfig
{{- if hasKey .Values "imagePullSecretNames" }}
imagePullSecrets:
{{- range .Values.imagePullSecretNames }}
- name: {{ . }}
{{- end }}
{{- end }}
13 changes: 13 additions & 0 deletions chart/apl/templates/git-secret.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
apiVersion: v1
kind: Secret
metadata:
name: gitea-credentials
namespace: apl-operator
type: Opaque
stringData:
{{- if .Values.gitUsername }}
GIT_USERNAME: {{ .Values.gitUsername | quote }}
{{- end }}
{{- if .Values.gitPassword }}
GIT_PASSWORD: {{ .Values.gitPassword | quote }}
{{- end }}
100 changes: 0 additions & 100 deletions chart/apl/templates/job.yaml

This file was deleted.

Loading
Loading