diff --git a/.github/workflows/charts.yml b/.github/workflows/charts.yml index 6c06a6a..00986ee 100644 --- a/.github/workflows/charts.yml +++ b/.github/workflows/charts.yml @@ -38,7 +38,7 @@ jobs: fi - name: Run chart-testing (lint) - run: ct lint --config config.yaml --target-branch ${{ github.event.repository.default_branch }} + run: ct lint --helm-extra-args "--timeout 10m" --config config.yaml --target-branch ${{ github.event.repository.default_branch }} - name: Create kind cluster uses: helm/kind-action@dda0770415bac9fc20092cacbc54aa298604d140 # v1.8.0 diff --git a/charts/feedbacksystem/Chart.lock b/charts/feedbacksystem/Chart.lock index 3facf6e..79f6352 100644 --- a/charts/feedbacksystem/Chart.lock +++ b/charts/feedbacksystem/Chart.lock @@ -17,5 +17,8 @@ dependencies: - name: postgresql repository: https://charts.bitnami.com/bitnami version: 12.12.10 -digest: sha256:3906467fe2b02a703574c5e6d58cf15e45f703a8b9bef1049f13367a116b9f25 -generated: "2023-11-11T21:56:37.840314053Z" +- name: postgresql + repository: https://charts.bitnami.com/bitnami + version: 12.12.10 +digest: sha256:36062ff06c5e5e14d7817e599b7afc4bd9ef7d47ce8e2d299c1ece7b46c27065 +generated: "2023-12-14T13:40:43.867954265+01:00" diff --git a/charts/feedbacksystem/Chart.yaml b/charts/feedbacksystem/Chart.yaml index e4c814f..be26bda 100644 --- a/charts/feedbacksystem/Chart.yaml +++ b/charts/feedbacksystem/Chart.yaml @@ -6,7 +6,7 @@ sources: - https://github.com/thm-mni-ii/feedbacksystem home: https://github.com/thm-mni-ii/feedbacksystem type: application -version: 0.31.3 +version: 0.32.0 # renovate: image=thmmniii/fbs-core appVersion: v1.13.3 dependencies: @@ -38,6 +38,11 @@ dependencies: repository: 'https://charts.bitnami.com/bitnami' condition: runner.enabled alias: runnerPlaygroundPostgres + - name: postgresql + version: 12.12.10 + repository: 'https://charts.bitnami.com/bitnami' + condition: runner.enabled + alias: playgroundSharePostgres maintainers: - name: zitrone44 annotations: diff --git a/charts/feedbacksystem/generate-values.ts b/charts/feedbacksystem/generate-values.ts index 0255ce7..9d2331e 100644 --- a/charts/feedbacksystem/generate-values.ts +++ b/charts/feedbacksystem/generate-values.ts @@ -74,6 +74,12 @@ function buildValues(): any { digitalClassroom: { enabled: false, }, + playgroundSharePostgres: { + auth: { + password: randomHex(), + postgresPassword: randomHex(), + }, + }, }; if (confirm("Configure digital classroom:")) { diff --git a/charts/feedbacksystem/templates/core.yaml b/charts/feedbacksystem/templates/core.yaml index 1e242e6..9535287 100644 --- a/charts/feedbacksystem/templates/core.yaml +++ b/charts/feedbacksystem/templates/core.yaml @@ -206,6 +206,21 @@ spec: configMapKeyRef: name: {{ .Release.Name }}-anti-brute-force key: allow_list + - name: SQL_PLAYGROUND_SHARE_PUBLIC_HOST + valueFrom: + configMapKeyRef: + name: {{ .Release.Name }}-core + key: sqlPlaygroundSharePublicHost + - name: SQL_PLAYGROUND_SHARE_PUBLIC_PORT + valueFrom: + configMapKeyRef: + name: {{ .Release.Name }}-core + key: sqlPlaygroundSharePublicPort + - name: ID_SALT + valueFrom: + configMapKeyRef: + name: {{ .Release.Name }}-core + key: idSalt resources: requests: cpu: {{ .Values.core.resources.cpu.request }} @@ -235,6 +250,9 @@ data: mysqlUser: {{ .Values.mysql.auth.username | quote }} minioUrl: {{ print "http://" .Release.Name "-minio" | quote }} classroomUrl: {{ include "digital-classroom-url" . | quote }} + sqlPlaygroundSharePublicHost: {{ .Values.core.config.sqlPlaygroundShare.publicHost | quote }} + sqlPlaygroundSharePublicPort: {{ .Values.core.config.sqlPlaygroundShare.publicPort | quote }} + idSalt: {{ .Values.core.config.id.salt | quote }} --- apiVersion: v1 kind: Secret diff --git a/charts/feedbacksystem/templates/runner.yaml b/charts/feedbacksystem/templates/runner.yaml index c85c1e7..24421a7 100644 --- a/charts/feedbacksystem/templates/runner.yaml +++ b/charts/feedbacksystem/templates/runner.yaml @@ -78,6 +78,21 @@ spec: secretKeyRef: name: {{ .Release.Name }}-runner key: playgroundPsqlPassword + - name: SQL_PLAYGROUND_SHARE_PSQL_SERVER_URL + valueFrom: + configMapKeyRef: + name: {{ .Release.Name }}-runner + key: playgroundSharePsqlJdbclUri + - name: SQL_PLAYGROUND_SHARE_PSQL_SERVER_USERNAME + valueFrom: + configMapKeyRef: + name: {{ .Release.Name }}-runner + key: playgroundSharePsqlUsername + - name: SQL_PLAYGROUND_SHARE_PSQL_SERVER_PASSWORD + valueFrom: + secretKeyRef: + name: {{ .Release.Name }}-runner + key: playgroundSharePsqlPassword - name: HMAC_SECRET valueFrom: secretKeyRef: @@ -148,9 +163,11 @@ data: mysqlJdbclUri: {{ print "jdbc:mysql://" .Release.Name "-runner-mysql:3306?allowMultiQueries=true" }} psqlJdbclUri: {{ print "jdbc:postgresql://" .Release.Name "-runner-postgres:5432/?allowMultiQueries=true" }} playgroundPsqlJdbclUri: {{ print "jdbc:postgresql://" .Release.Name "-runner-playground-postgres:5432/?allowMultiQueries=true" }} + playgroundSharePsqlJdbclUri: {{ print "jdbc:postgresql://" .Release.Name "-playground-share-postgres:5432/?allowMultiQueries=true" }} mysqlUsername: 'root' psqlUsername: 'postgres' playgroundPsqlUsername: 'postgres' + playgroundSharePsqlUsername: 'postgres' --- apiVersion: v1 kind: Secret @@ -161,6 +178,7 @@ data: mysqlPassword: {{ .Values.runnerMysql.auth.rootPassword | b64enc }} psqlPassword: {{ .Values.runnerPostgres.auth.postgresPassword | b64enc }} playgroundPsqlPassword: {{ .Values.runnerPlaygroundPostgres.auth.postgresPassword | b64enc }} + playgroundSharePsqlPassword: {{ .Values.playgroundSharePostgres.auth.postgresPassword | b64enc }} hmacSecret: {{ .Values.runner.config.hmacSecret | b64enc }} --- apiVersion: v1 diff --git a/charts/feedbacksystem/values.yaml b/charts/feedbacksystem/values.yaml index 3ec9c88..a7b5323 100644 --- a/charts/feedbacksystem/values.yaml +++ b/charts/feedbacksystem/values.yaml @@ -52,6 +52,11 @@ core: interval: 600 maxAttempts: 10 allowList: [] + sqlPlaygroundShare: + publicHost: "127.0.0.1" + publicPort: 4321 + id: + salt: "fbs-helm-chart-salt" # Change me if you want different ids ingressRoute: enabled: false @@ -173,6 +178,14 @@ runnerPlaygroundPostgres: password: fbs # CHANGE ME postgresPassword: root # CHANGE ME +playgroundSharePostgres: + nameOverride: playground-share-postgres + auth: + database: fbs + username: fbs + password: fbs # CHANGE ME + postgresPassword: root # CHANGE ME + checkerMongodb: nameOverride: checker-mongodb useStatefulSet: true