Compare commits
52 Commits
feature/va
...
feature/pp
| Author | SHA1 | Date | |
|---|---|---|---|
| 1808750c81 | |||
| 82a081d6a3 | |||
| c49d03d7f7 | |||
| d47dba2ae5 | |||
| cf9eb47ecf | |||
| 3eca723f05 | |||
| f36996da11 | |||
| 6bf7db21d0 | |||
| 2641d55784 | |||
| 117297effc | |||
| fda90f9e01 | |||
| 1124377d97 | |||
| c0710b89bb | |||
| d7bda18aea | |||
| 2796e1b9d3 | |||
| d7a0c26117 | |||
| 693f2f9168 | |||
| 2509ef062c | |||
| 957757e557 | |||
| 070799da05 | |||
| 1a2817e537 | |||
| b47b0035f5 | |||
| d3fac4d43e | |||
| c37bd3ef04 | |||
| ad661ba3dd | |||
| a9625f96e6 | |||
| cb64edc927 | |||
| ac1c242fb9 | |||
| 4b29c07fd6 | |||
| 52732626e5 | |||
| 8634436dd4 | |||
| a8baa169e9 | |||
| 73ef3a6e12 | |||
| 302705d374 | |||
| f3286ef77e | |||
| 74f4f86770 | |||
| f2c56156bf | |||
| 21fb50ba00 | |||
| b90b630b06 | |||
| 66de9b8a0a | |||
| 716c552be9 | |||
| f048b47a0f | |||
| 66f40427ee | |||
| 332881cbd0 | |||
| f363afa087 | |||
| bc42347cb6 | |||
| 80d7bff4bc | |||
| 3644a3ec87 | |||
| bd478478f1 | |||
| 67b1d95509 | |||
| fff95d98a5 | |||
| 8b743efa43 |
@@ -1063,6 +1063,52 @@ dind:
|
|||||||
- Gitea admin panel (`/admin/runners`) — runners show as Online
|
- Gitea admin panel (`/admin/runners`) — runners show as Online
|
||||||
- Create test workflow in `.gitea/workflows/test.yml` — job executes
|
- Create test workflow in `.gitea/workflows/test.yml` — job executes
|
||||||
|
|
||||||
|
### Vaultwarden
|
||||||
|
|
||||||
|
**Chart**: `guerzon/vaultwarden`
|
||||||
|
**Version**: 0.36.4 (app v1.36.0-alpine)
|
||||||
|
**Namespace**: `vaultwarden`
|
||||||
|
|
||||||
|
**Purpose**: Self-hosted Bitwarden-compatible password manager.
|
||||||
|
|
||||||
|
**Configuration**:
|
||||||
|
```yaml
|
||||||
|
# infra/overlays/upc-dev/vaultwarden/ + infra/values/
|
||||||
|
domain: "https://bitwarden.forteapps.net"
|
||||||
|
|
||||||
|
ingress:
|
||||||
|
enabled: true
|
||||||
|
class: "traefik"
|
||||||
|
tls: true
|
||||||
|
tlsSecret: vaultwarden-tls
|
||||||
|
hostname: bitwarden.forteapps.net
|
||||||
|
additionalAnnotations:
|
||||||
|
cert-manager.io/cluster-issuer: letsencrypt-prod
|
||||||
|
|
||||||
|
database:
|
||||||
|
type: postgresql
|
||||||
|
host: vaultwarden-postgresql # StatefulSet in overlay
|
||||||
|
existingSecret: prod-db-creds
|
||||||
|
|
||||||
|
storage:
|
||||||
|
data: 5Gi (ReadWriteOnce)
|
||||||
|
attachments: 5Gi (ReadWriteOnce)
|
||||||
|
```
|
||||||
|
|
||||||
|
**TLS**: cert-manager auto-provisions Let's Encrypt certificate via `letsencrypt-prod` ClusterIssuer (same pattern as Gitea, Grafana, etc).
|
||||||
|
|
||||||
|
**SSO**: Keycloak OIDC via `forte` realm (client ID: `vaultwarden`). Self-service client config Secret (`keycloak-client-vaultwarden`) triggers registrar to create KC client and sync credentials to `vaultwarden-oidc-credentials`. PKCE enabled.
|
||||||
|
|
||||||
|
**Endpoints**:
|
||||||
|
- Web UI: `https://bitwarden.forteapps.net`
|
||||||
|
|
||||||
|
**Database**: Separate ArgoCD Application `vaultwarden-postgresql` (sync-wave `"0"`) deploys PostgreSQL 16 StatefulSet + SealedSecret before Vaultwarden (wave `"1"`). 2Gi PVC. Chart does NOT include a PostgreSQL subchart — must be provisioned separately.
|
||||||
|
|
||||||
|
**Secrets**:
|
||||||
|
- `prod-db-creds` (SealedSecret) — PostgreSQL credentials (`pgusername`, `pgpassword`) + SMTP credentials
|
||||||
|
- `vaultwarden-oidc-credentials` (registrar-managed) — OIDC client ID + secret
|
||||||
|
- `vaultwarden-tls` — auto-managed by cert-manager
|
||||||
|
|
||||||
### AI Code Review (ai-review)
|
### AI Code Review (ai-review)
|
||||||
|
|
||||||
**Type**: Gitea Actions workflow (`.gitea/workflows/ai-review.yaml`)
|
**Type**: Gitea Actions workflow (`.gitea/workflows/ai-review.yaml`)
|
||||||
@@ -1141,6 +1187,30 @@ ignore:
|
|||||||
- Check Gitea Actions tab for workflow run status and logs
|
- Check Gitea Actions tab for workflow run status and logs
|
||||||
- Monitor Anthropic usage dashboard for token consumption
|
- Monitor Anthropic usage dashboard for token consumption
|
||||||
|
|
||||||
|
### Keycloak Browser Flow (IdP Auto-Redirect)
|
||||||
|
|
||||||
|
**File**: `infra/values/base/keycloak-values.yaml` (inside `forte-realm.json`)
|
||||||
|
|
||||||
|
The realm uses a custom browser authentication flow (`browser-auto-idp`) that skips the Keycloak login page and redirects directly to the Entra ID identity provider.
|
||||||
|
|
||||||
|
**Flow executions**:
|
||||||
|
|
||||||
|
| Priority | Authenticator | Requirement | Purpose |
|
||||||
|
|----------|--------------|-------------|---------|
|
||||||
|
| 10 | `auth-cookie` | ALTERNATIVE | Reuse existing session (no redirect) |
|
||||||
|
| 20 | `identity-provider-redirector` | ALTERNATIVE | Auto-redirect to `forte-entra` IdP |
|
||||||
|
|
||||||
|
**Key fields in realm JSON**:
|
||||||
|
- `"browserFlow": "browser-auto-idp"` — overrides the default `browser` flow at realm level
|
||||||
|
- `"authenticationFlows"` — defines the custom flow with its executions
|
||||||
|
- `"authenticatorConfig"` — sets `defaultProvider: "forte-entra"` on the redirector
|
||||||
|
|
||||||
|
**Why custom flow**: The default KC browser flow shows a username/password form with an IdP button. Since all authentication is via Entra ID, the custom flow eliminates this step. The `auth-cookie` execution preserves session reuse so returning users aren't redirected again.
|
||||||
|
|
||||||
|
**Important**: The `forte-entra` identity provider must exist in Keycloak (currently configured manually in the KC admin console). If the IdP alias changes, update the `defaultProvider` value in the realm JSON.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
### Keycloak Client Registrar
|
### Keycloak Client Registrar
|
||||||
|
|
||||||
**Type**: CronJob (deployed via Keycloak Helm chart `extraDeploy`)
|
**Type**: CronJob (deployed via Keycloak Helm chart `extraDeploy`)
|
||||||
|
|||||||
@@ -43,10 +43,6 @@ spec:
|
|||||||
- ServerSideApply=true
|
- ServerSideApply=true
|
||||||
|
|
||||||
ignoreDifferences:
|
ignoreDifferences:
|
||||||
- group: batch
|
|
||||||
kind: CronJob
|
|
||||||
jsonPointers:
|
|
||||||
- /spec/jobTemplate/spec/template/spec/containers/0/args
|
|
||||||
- group: apps
|
- group: apps
|
||||||
kind: StatefulSet
|
kind: StatefulSet
|
||||||
jsonPointers:
|
jsonPointers:
|
||||||
|
|||||||
@@ -2,6 +2,10 @@ apiVersion: kustomize.config.k8s.io/v1beta1
|
|||||||
kind: Kustomization
|
kind: Kustomization
|
||||||
resources:
|
resources:
|
||||||
- ../../base
|
- ../../base
|
||||||
|
- vaultwarden-postgresql
|
||||||
|
- vaultwarden
|
||||||
|
- passwordpusher-postgresql
|
||||||
|
- passwordpusher
|
||||||
|
|
||||||
# No patches needed — base already has "upc-dev" paths
|
# No patches needed — base already has "upc-dev" paths
|
||||||
# upc-dev is the default/base cluster
|
# upc-dev is the default/base cluster
|
||||||
|
|||||||
@@ -0,0 +1,4 @@
|
|||||||
|
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||||
|
kind: Kustomization
|
||||||
|
resources:
|
||||||
|
- passwordpusher-postgresql.yaml
|
||||||
@@ -0,0 +1,46 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Namespace
|
||||||
|
metadata:
|
||||||
|
name: passwordpusher
|
||||||
|
---
|
||||||
|
|
||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: Application
|
||||||
|
metadata:
|
||||||
|
name: passwordpusher-postgresql
|
||||||
|
namespace: argocd
|
||||||
|
annotations:
|
||||||
|
argocd.argoproj.io/sync-wave: "0"
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: passwordpusher-postgresql
|
||||||
|
app.kubernetes.io/part-of: security
|
||||||
|
app.kubernetes.io/managed-by: argocd
|
||||||
|
finalizers:
|
||||||
|
- resources-finalizer.argocd.argoproj.io
|
||||||
|
spec:
|
||||||
|
project: default
|
||||||
|
|
||||||
|
source:
|
||||||
|
repoURL: ssh://git@git.forteapps.net:2222/Forte/launchpad.git
|
||||||
|
targetRevision: HEAD
|
||||||
|
path: infra/overlays/upc-dev/passwordpusher-postgresql/resources
|
||||||
|
|
||||||
|
destination:
|
||||||
|
server: https://kubernetes.default.svc
|
||||||
|
namespace: passwordpusher
|
||||||
|
|
||||||
|
syncPolicy:
|
||||||
|
automated:
|
||||||
|
prune: true
|
||||||
|
selfHeal: true
|
||||||
|
allowEmpty: false
|
||||||
|
syncOptions:
|
||||||
|
- CreateNamespace=true
|
||||||
|
- Validate=true
|
||||||
|
- ServerSideApply=true
|
||||||
|
|
||||||
|
ignoreDifferences:
|
||||||
|
- group: apps
|
||||||
|
kind: StatefulSet
|
||||||
|
jsonPointers:
|
||||||
|
- /spec/volumeClaimTemplates
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||||
|
kind: Kustomization
|
||||||
|
resources:
|
||||||
|
- postgresql.yaml
|
||||||
|
- passwordpusher-db-secret-sealed.yaml
|
||||||
|
- passwordpusher-smtp-secret-sealed.yaml
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
---
|
||||||
|
apiVersion: bitnami.com/v1alpha1
|
||||||
|
kind: SealedSecret
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
name: passwordpusher-db-creds
|
||||||
|
namespace: passwordpusher
|
||||||
|
spec:
|
||||||
|
encryptedData:
|
||||||
|
DATABASE_URL: AgBeCVhdJoq18FFbP/8CUFFHBu3cUHisStmqeU3stH33qRgm0sh1Agw87QaiECBlKGp9yEjDVgQEjU/h9vEqs5L13vnzTvzmzEIMy23m1nWEyX6pY06O/ISDD6AVeW73SX6ctgZ4wabv8z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:
|
||||||
|
creationTimestamp: null
|
||||||
|
name: passwordpusher-db-creds
|
||||||
|
namespace: passwordpusher
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
---
|
||||||
|
apiVersion: bitnami.com/v1alpha1
|
||||||
|
kind: SealedSecret
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
name: passwordpusher-smtp-creds
|
||||||
|
namespace: passwordpusher
|
||||||
|
spec:
|
||||||
|
encryptedData:
|
||||||
|
PWP__MAIL_SMTP_PASSWORD: AgBgRYGOS6O5u6WDXxfqkLsVClufJe8O0K3/NBWKEnwKFKd/yeQVnkB/sd2apIFADK6auge+G5uFv9TejWJuqkU3QHbkvmnjnMtinRkt/lh0GrrCygmvzvwTQKCXefeqWHT5yvGtN0z6mLP73yOLoJmAMnZk9/QGHuw9jfuLEDREZ3cSrdYAAIWhospSPpvau2UNN2/yanjhmH0Yux2fZVkwKtDcS6YHFtL+s4VR7wcB/cvMaCX4vSezMtyQJhgHcmFLNHnNjjVdMEQVGMtrZ7XocbWJ0ZkvKotkuOFf/XMq5AM9ZVgaJB9di39JLweqpsfGVQJftgGW/f/edDSlbiOTjDO2cM93xY9OD9T2kts5MkeX1jLD+Q+V0OXL7+nor1jAfv/CwZ5sBibnQFKYaQpCRCw4c4pYX73VjbRsEcTHXJyfUpTJdlw8Jd3yPPL1Uqb6ga5xxUO7YsgfdH4HZYWuLR/x8Pk1Ne/qpctzHZcUkRto6MKPhkK1IW83qSJPGT3wNHgYcx6uMW9f9L/ox7k00GGWZ3Pj79khv9NJ8PXO0thsTuZktjskHYBmZk044CWpSiill0318pCaIXW6mpg5adGbeZLa+LZ9GNxMWP+iOJIcFyYNZs3GmlV08OQ741S2cbumOQhxppJkcWTdpkZrZlAanLa4XZsmW+PXmsujOsMLEuto3PpJxpujYAt3s6Nv7O79FlGqrfisRipdFw==
|
||||||
|
PWP__MAIL_SMTP_USER_NAME: AgAli4SWEtNSiuRvbhuAYdRtBPpPYQfVp1cjiPXUqX7CxBG6bOdlMFzUPnjmZ3RVDq8UaRbwF1eJisnLt1nRCh5+DzpOXNgiU8ex2uZx7mQPf/nr/5p1HwJHbMZUo6Qieqo8NIwA0fwapQPsLizI90wI2J8f4m4nk4SXb0FW0h23SpulEJV99w92TPdOd/KuovVzEFltWeCWOsaHdVufKDsKLMFc4SNrkBwYxaCkuGnM6zICiLc7+5lF7cza8JukfGXsF12U04CkqgMDOOQG4GNNIeGSOc2GGtngpmYbuKZA1vk8ZnG3K+nVyD12bW2JhvWOBpNSc+29gLbizkNGI8QLhlxet3HznjYal9aqiIR2/glZgIUsnmgwmVg+VpxnM6A/R47sljeIzyzY0dkVxDyG1fDfKiWmXIWQU/7750Ct8XgMsVIkyDGQAK2g8o97a75lSnTngGq88VvTBLCiSEgumhPrMYf4n7ot4tSM1lfGuxmYdrOKXqXNkhBF+jxe27pd4ayCzcXniibZKRqhCozZZkAoYoo+V8tnIlewrTJhzm9THgKL849Df3Va9tI7EOvqHy82FjwTL++jCpUrOe1Emp11WpUJElnn+PUWRJnW02Xz+a0vP+mJMjC1XsylDM78i31a6Tw8Rfu7W4G7yuwzgU9GDCDL6dt7nsGUSNuucZz7CVx2pePFLWJBC8DmcuuWh/UlnrNp8IY/9kC34DAbwuBTQuFhYne1xWSA
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
name: passwordpusher-smtp-creds
|
||||||
|
namespace: passwordpusher
|
||||||
@@ -0,0 +1,98 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: passwordpusher-postgresql
|
||||||
|
namespace: passwordpusher
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: postgresql
|
||||||
|
app.kubernetes.io/instance: passwordpusher
|
||||||
|
app.kubernetes.io/component: database
|
||||||
|
spec:
|
||||||
|
type: ClusterIP
|
||||||
|
ports:
|
||||||
|
- name: tcp-postgresql
|
||||||
|
port: 5432
|
||||||
|
targetPort: tcp-postgresql
|
||||||
|
selector:
|
||||||
|
app.kubernetes.io/name: postgresql
|
||||||
|
app.kubernetes.io/instance: passwordpusher
|
||||||
|
---
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: StatefulSet
|
||||||
|
metadata:
|
||||||
|
name: passwordpusher-postgresql
|
||||||
|
namespace: passwordpusher
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: postgresql
|
||||||
|
app.kubernetes.io/instance: passwordpusher
|
||||||
|
app.kubernetes.io/component: database
|
||||||
|
spec:
|
||||||
|
serviceName: passwordpusher-postgresql
|
||||||
|
replicas: 1
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app.kubernetes.io/name: postgresql
|
||||||
|
app.kubernetes.io/instance: passwordpusher
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: postgresql
|
||||||
|
app.kubernetes.io/instance: passwordpusher
|
||||||
|
app.kubernetes.io/component: database
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- name: postgresql
|
||||||
|
image: postgres:16-alpine
|
||||||
|
ports:
|
||||||
|
- name: tcp-postgresql
|
||||||
|
containerPort: 5432
|
||||||
|
env:
|
||||||
|
- name: POSTGRES_USER
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: passwordpusher-db-creds
|
||||||
|
key: pgusername
|
||||||
|
- name: POSTGRES_PASSWORD
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: passwordpusher-db-creds
|
||||||
|
key: pgpassword
|
||||||
|
- name: POSTGRES_DB
|
||||||
|
value: passwordpusher
|
||||||
|
- name: PGDATA
|
||||||
|
value: /var/lib/postgresql/data/pgdata
|
||||||
|
volumeMounts:
|
||||||
|
- name: data
|
||||||
|
mountPath: /var/lib/postgresql/data
|
||||||
|
livenessProbe:
|
||||||
|
exec:
|
||||||
|
command:
|
||||||
|
- sh
|
||||||
|
- -c
|
||||||
|
- pg_isready -U "$POSTGRES_USER" -d passwordpusher
|
||||||
|
initialDelaySeconds: 30
|
||||||
|
periodSeconds: 10
|
||||||
|
readinessProbe:
|
||||||
|
exec:
|
||||||
|
command:
|
||||||
|
- sh
|
||||||
|
- -c
|
||||||
|
- pg_isready -U "$POSTGRES_USER" -d passwordpusher
|
||||||
|
initialDelaySeconds: 5
|
||||||
|
periodSeconds: 5
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
cpu: 100m
|
||||||
|
memory: 256Mi
|
||||||
|
limits:
|
||||||
|
cpu: 500m
|
||||||
|
memory: 512Mi
|
||||||
|
volumeClaimTemplates:
|
||||||
|
- metadata:
|
||||||
|
name: data
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 2Gi
|
||||||
4
infra/overlays/upc-dev/passwordpusher/kustomization.yaml
Normal file
4
infra/overlays/upc-dev/passwordpusher/kustomization.yaml
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||||
|
kind: Kustomization
|
||||||
|
resources:
|
||||||
|
- passwordpusher.yaml
|
||||||
43
infra/overlays/upc-dev/passwordpusher/passwordpusher.yaml
Normal file
43
infra/overlays/upc-dev/passwordpusher/passwordpusher.yaml
Normal file
@@ -0,0 +1,43 @@
|
|||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: Application
|
||||||
|
metadata:
|
||||||
|
name: passwordpusher
|
||||||
|
namespace: argocd
|
||||||
|
annotations:
|
||||||
|
argocd.argoproj.io/sync-wave: "1"
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: passwordpusher
|
||||||
|
app.kubernetes.io/part-of: security
|
||||||
|
app.kubernetes.io/managed-by: argocd
|
||||||
|
finalizers:
|
||||||
|
- resources-finalizer.argocd.argoproj.io
|
||||||
|
spec:
|
||||||
|
project: default
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- repoURL: https://pglombardo.github.io/passwordpusher-charts
|
||||||
|
chart: password-pusher
|
||||||
|
targetRevision: "1.4.4"
|
||||||
|
helm:
|
||||||
|
releaseName: passwordpusher
|
||||||
|
valueFiles:
|
||||||
|
- $values/infra/values/base/passwordpusher-values.yaml
|
||||||
|
- $values/infra/values/upc-dev/passwordpusher-values.yaml
|
||||||
|
|
||||||
|
- repoURL: ssh://git@git.forteapps.net:2222/Forte/launchpad.git
|
||||||
|
targetRevision: HEAD
|
||||||
|
ref: values
|
||||||
|
|
||||||
|
destination:
|
||||||
|
server: https://kubernetes.default.svc
|
||||||
|
namespace: passwordpusher
|
||||||
|
|
||||||
|
syncPolicy:
|
||||||
|
automated:
|
||||||
|
prune: true
|
||||||
|
selfHeal: true
|
||||||
|
allowEmpty: false
|
||||||
|
syncOptions:
|
||||||
|
- CreateNamespace=true
|
||||||
|
- Validate=true
|
||||||
|
- ServerSideApply=true
|
||||||
@@ -0,0 +1,4 @@
|
|||||||
|
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||||
|
kind: Kustomization
|
||||||
|
resources:
|
||||||
|
- vaultwarden-postgresql.yaml
|
||||||
@@ -0,0 +1,5 @@
|
|||||||
|
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||||
|
kind: Kustomization
|
||||||
|
resources:
|
||||||
|
- postgresql.yaml
|
||||||
|
- vaultwarden-db-secret-sealed.yaml
|
||||||
@@ -0,0 +1,98 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Service
|
||||||
|
metadata:
|
||||||
|
name: vaultwarden-postgresql
|
||||||
|
namespace: vaultwarden
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: postgresql
|
||||||
|
app.kubernetes.io/instance: vaultwarden
|
||||||
|
app.kubernetes.io/component: database
|
||||||
|
spec:
|
||||||
|
type: ClusterIP
|
||||||
|
ports:
|
||||||
|
- name: tcp-postgresql
|
||||||
|
port: 5432
|
||||||
|
targetPort: tcp-postgresql
|
||||||
|
selector:
|
||||||
|
app.kubernetes.io/name: postgresql
|
||||||
|
app.kubernetes.io/instance: vaultwarden
|
||||||
|
---
|
||||||
|
apiVersion: apps/v1
|
||||||
|
kind: StatefulSet
|
||||||
|
metadata:
|
||||||
|
name: vaultwarden-postgresql
|
||||||
|
namespace: vaultwarden
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: postgresql
|
||||||
|
app.kubernetes.io/instance: vaultwarden
|
||||||
|
app.kubernetes.io/component: database
|
||||||
|
spec:
|
||||||
|
serviceName: vaultwarden-postgresql
|
||||||
|
replicas: 1
|
||||||
|
selector:
|
||||||
|
matchLabels:
|
||||||
|
app.kubernetes.io/name: postgresql
|
||||||
|
app.kubernetes.io/instance: vaultwarden
|
||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: postgresql
|
||||||
|
app.kubernetes.io/instance: vaultwarden
|
||||||
|
app.kubernetes.io/component: database
|
||||||
|
spec:
|
||||||
|
containers:
|
||||||
|
- name: postgresql
|
||||||
|
image: postgres:16-alpine
|
||||||
|
ports:
|
||||||
|
- name: tcp-postgresql
|
||||||
|
containerPort: 5432
|
||||||
|
env:
|
||||||
|
- name: POSTGRES_USER
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: prod-db-creds
|
||||||
|
key: pgusername
|
||||||
|
- name: POSTGRES_PASSWORD
|
||||||
|
valueFrom:
|
||||||
|
secretKeyRef:
|
||||||
|
name: prod-db-creds
|
||||||
|
key: pgpassword
|
||||||
|
- name: POSTGRES_DB
|
||||||
|
value: vaultwarden
|
||||||
|
- name: PGDATA
|
||||||
|
value: /var/lib/postgresql/data/pgdata
|
||||||
|
volumeMounts:
|
||||||
|
- name: data
|
||||||
|
mountPath: /var/lib/postgresql/data
|
||||||
|
livenessProbe:
|
||||||
|
exec:
|
||||||
|
command:
|
||||||
|
- sh
|
||||||
|
- -c
|
||||||
|
- pg_isready -U "$POSTGRES_USER" -d vaultwarden
|
||||||
|
initialDelaySeconds: 30
|
||||||
|
periodSeconds: 10
|
||||||
|
readinessProbe:
|
||||||
|
exec:
|
||||||
|
command:
|
||||||
|
- sh
|
||||||
|
- -c
|
||||||
|
- pg_isready -U "$POSTGRES_USER" -d vaultwarden
|
||||||
|
initialDelaySeconds: 5
|
||||||
|
periodSeconds: 5
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
cpu: 100m
|
||||||
|
memory: 256Mi
|
||||||
|
limits:
|
||||||
|
cpu: 500m
|
||||||
|
memory: 512Mi
|
||||||
|
volumeClaimTemplates:
|
||||||
|
- metadata:
|
||||||
|
name: data
|
||||||
|
spec:
|
||||||
|
accessModes:
|
||||||
|
- ReadWriteOnce
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
storage: 2Gi
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
---
|
||||||
|
apiVersion: bitnami.com/v1alpha1
|
||||||
|
kind: SealedSecret
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
name: prod-db-creds
|
||||||
|
namespace: vaultwarden
|
||||||
|
spec:
|
||||||
|
encryptedData:
|
||||||
|
DATABASE_URL: AgAy1d//kBevUqZxB5KAXd+qxm8QykNxp5J1QP7Y30XCpE8hldPXF+NIx3w0B0PUyMAVsa+JrBmCMtzgibddIJqqF2upu/8EYxJZNusrJPOi47g3VcZIg1WyxoFfffH6jwhzv69TE/T8WGBXmWbD2vr+XWjE24Q+lgwLut0mocVfihUjpuYq0WDjgJx7pqLnY1VatTwgSkAv1uRRVqdi7e1M5isDNEpdItCbEoWwdvZhG5JIMAA/2vecY4/vEne3cg46lJAkv4ueZNATG6DOXGgQgz6h7zCKSGS1xTfGr+4A2V2/vSYpQ/r8Td37mlseoBvwN4H5O+FgHrVREm7N6aafDariYd+ZfqUIGObsZIXhxhDmAM96pjtP8ehYVwq1srWTU+SUewEmwLFWhVP1UFnTB5vgIuOWoKjHlS7dSUpStpw2u7/mQ6vhRhEaDqY6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||||||
|
template:
|
||||||
|
metadata:
|
||||||
|
creationTimestamp: null
|
||||||
|
name: prod-db-creds
|
||||||
|
namespace: vaultwarden
|
||||||
@@ -0,0 +1,46 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Namespace
|
||||||
|
metadata:
|
||||||
|
name: vaultwarden
|
||||||
|
---
|
||||||
|
|
||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: Application
|
||||||
|
metadata:
|
||||||
|
name: vaultwarden-postgresql
|
||||||
|
namespace: argocd
|
||||||
|
annotations:
|
||||||
|
argocd.argoproj.io/sync-wave: "0"
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: vaultwarden-postgresql
|
||||||
|
app.kubernetes.io/part-of: security
|
||||||
|
app.kubernetes.io/managed-by: argocd
|
||||||
|
finalizers:
|
||||||
|
- resources-finalizer.argocd.argoproj.io
|
||||||
|
spec:
|
||||||
|
project: default
|
||||||
|
|
||||||
|
source:
|
||||||
|
repoURL: ssh://git@git.forteapps.net:2222/Forte/launchpad.git
|
||||||
|
targetRevision: HEAD
|
||||||
|
path: infra/overlays/upc-dev/vaultwarden-postgresql/resources
|
||||||
|
|
||||||
|
destination:
|
||||||
|
server: https://kubernetes.default.svc
|
||||||
|
namespace: vaultwarden
|
||||||
|
|
||||||
|
syncPolicy:
|
||||||
|
automated:
|
||||||
|
prune: true
|
||||||
|
selfHeal: true
|
||||||
|
allowEmpty: false
|
||||||
|
syncOptions:
|
||||||
|
- CreateNamespace=true
|
||||||
|
- Validate=true
|
||||||
|
- ServerSideApply=true
|
||||||
|
|
||||||
|
ignoreDifferences:
|
||||||
|
- group: apps
|
||||||
|
kind: StatefulSet
|
||||||
|
jsonPointers:
|
||||||
|
- /spec/volumeClaimTemplates
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
apiVersion: v1
|
||||||
|
kind: Secret
|
||||||
|
metadata:
|
||||||
|
name: keycloak-client-vaultwarden
|
||||||
|
namespace: vaultwarden
|
||||||
|
labels:
|
||||||
|
keycloak.forteapps.net/client-config: "true"
|
||||||
|
stringData:
|
||||||
|
client.json: |
|
||||||
|
{
|
||||||
|
"clientId": "vaultwarden",
|
||||||
|
"name": "Vaultwarden",
|
||||||
|
"redirectUris": ["https://vaultwarden.forteapps.net/*"],
|
||||||
|
"webOrigins": ["https://vaultwarden.forteapps.net"],
|
||||||
|
"protocolMappers": [],
|
||||||
|
"secret": {
|
||||||
|
"namespace": "vaultwarden",
|
||||||
|
"name": "vaultwarden-oidc-credentials",
|
||||||
|
"keys": { "clientId": "client-id", "clientSecret": "client-secret" }
|
||||||
|
}
|
||||||
|
}
|
||||||
5
infra/overlays/upc-dev/vaultwarden/kustomization.yaml
Normal file
5
infra/overlays/upc-dev/vaultwarden/kustomization.yaml
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
apiVersion: kustomize.config.k8s.io/v1beta1
|
||||||
|
kind: Kustomization
|
||||||
|
resources:
|
||||||
|
- vaultwarden.yaml
|
||||||
|
- keycloak-client-config.yaml
|
||||||
43
infra/overlays/upc-dev/vaultwarden/vaultwarden.yaml
Normal file
43
infra/overlays/upc-dev/vaultwarden/vaultwarden.yaml
Normal file
@@ -0,0 +1,43 @@
|
|||||||
|
apiVersion: argoproj.io/v1alpha1
|
||||||
|
kind: Application
|
||||||
|
metadata:
|
||||||
|
name: vaultwarden
|
||||||
|
namespace: argocd
|
||||||
|
annotations:
|
||||||
|
argocd.argoproj.io/sync-wave: "1"
|
||||||
|
labels:
|
||||||
|
app.kubernetes.io/name: vaultwarden
|
||||||
|
app.kubernetes.io/part-of: security
|
||||||
|
app.kubernetes.io/managed-by: argocd
|
||||||
|
finalizers:
|
||||||
|
- resources-finalizer.argocd.argoproj.io
|
||||||
|
spec:
|
||||||
|
project: default
|
||||||
|
|
||||||
|
sources:
|
||||||
|
- repoURL: https://guerzon.github.io/vaultwarden
|
||||||
|
chart: vaultwarden
|
||||||
|
targetRevision: "0.36.4"
|
||||||
|
helm:
|
||||||
|
releaseName: vaultwarden
|
||||||
|
valueFiles:
|
||||||
|
- $values/infra/values/base/vaultwarden-values.yaml
|
||||||
|
- $values/infra/values/upc-dev/vaultwarden-values.yaml
|
||||||
|
|
||||||
|
- repoURL: ssh://git@git.forteapps.net:2222/Forte/launchpad.git
|
||||||
|
targetRevision: HEAD
|
||||||
|
ref: values
|
||||||
|
|
||||||
|
destination:
|
||||||
|
server: https://kubernetes.default.svc
|
||||||
|
namespace: vaultwarden
|
||||||
|
|
||||||
|
syncPolicy:
|
||||||
|
automated:
|
||||||
|
prune: true
|
||||||
|
selfHeal: true
|
||||||
|
allowEmpty: false
|
||||||
|
syncOptions:
|
||||||
|
- CreateNamespace=true
|
||||||
|
- Validate=true
|
||||||
|
- ServerSideApply=true
|
||||||
@@ -41,6 +41,7 @@ gitea:
|
|||||||
oauth2:
|
oauth2:
|
||||||
ENABLED: true
|
ENABLED: true
|
||||||
ENABLE_AUTO_REGISTRATION: true
|
ENABLE_AUTO_REGISTRATION: true
|
||||||
|
ACCOUNT_LINKING: auto
|
||||||
USERNAME: email
|
USERNAME: email
|
||||||
|
|
||||||
session:
|
session:
|
||||||
|
|||||||
@@ -58,6 +58,9 @@ keycloakConfigCli:
|
|||||||
enabled: true
|
enabled: true
|
||||||
image:
|
image:
|
||||||
repository: bitnamilegacy/keycloak-config-cli
|
repository: bitnamilegacy/keycloak-config-cli
|
||||||
|
extraEnvVars:
|
||||||
|
- name: IMPORT_MANAGED_PROTOCOL_MAPPER
|
||||||
|
value: "no-delete"
|
||||||
configuration:
|
configuration:
|
||||||
forte-realm.json: |
|
forte-realm.json: |
|
||||||
{
|
{
|
||||||
@@ -101,6 +104,18 @@ keycloakConfigCli:
|
|||||||
"access.token.claim": "true",
|
"access.token.claim": "true",
|
||||||
"userinfo.token.claim": "true"
|
"userinfo.token.claim": "true"
|
||||||
}
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "groups",
|
||||||
|
"protocol": "openid-connect",
|
||||||
|
"protocolMapper": "oidc-group-membership-mapper",
|
||||||
|
"config": {
|
||||||
|
"claim.name": "groups",
|
||||||
|
"full.path": "false",
|
||||||
|
"id.token.claim": "true",
|
||||||
|
"access.token.claim": "true",
|
||||||
|
"userinfo.token.claim": "true"
|
||||||
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
@@ -173,7 +188,54 @@ keycloakConfigCli:
|
|||||||
]
|
]
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
|
"browserFlow": "browser-auto-idp",
|
||||||
|
"authenticationFlows": [
|
||||||
|
{
|
||||||
|
"alias": "browser-auto-idp",
|
||||||
|
"description": "Browser flow with auto-redirect to Forte Entra IdP",
|
||||||
|
"providerId": "basic-flow",
|
||||||
|
"topLevel": true,
|
||||||
|
"builtIn": false,
|
||||||
|
"authenticationExecutions": [
|
||||||
|
{
|
||||||
|
"authenticator": "auth-cookie",
|
||||||
|
"authenticatorFlow": false,
|
||||||
|
"requirement": "ALTERNATIVE",
|
||||||
|
"priority": 10
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"authenticator": "identity-provider-redirector",
|
||||||
|
"authenticatorFlow": false,
|
||||||
|
"requirement": "ALTERNATIVE",
|
||||||
|
"priority": 20,
|
||||||
|
"authenticatorConfig": "forte-entra-redirector"
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"authenticatorConfig": [
|
||||||
|
{
|
||||||
|
"alias": "forte-entra-redirector",
|
||||||
|
"config": {
|
||||||
|
"defaultProvider": "forte-entra"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
"groups": [
|
"groups": [
|
||||||
|
{
|
||||||
|
"name": "k8s",
|
||||||
|
"path": "/k8s",
|
||||||
|
"clientRoles": {
|
||||||
|
"grafana": ["Editor"]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "dev",
|
||||||
|
"path": "/dev",
|
||||||
|
"clientRoles": {
|
||||||
|
"grafana": ["Viewer"]
|
||||||
|
}
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "ArgoCD Admins",
|
"name": "ArgoCD Admins",
|
||||||
"path": "/ArgoCD Admins"
|
"path": "/ArgoCD Admins"
|
||||||
@@ -443,10 +505,10 @@ extraDeploy:
|
|||||||
CRED_SECRET_KEY=$(echo "$CLIENT_JSON" | jq -r '.secret.keys.clientSecret // "client-secret"')
|
CRED_SECRET_KEY=$(echo "$CLIENT_JSON" | jq -r '.secret.keys.clientSecret // "client-secret"')
|
||||||
|
|
||||||
# Check if credential Secret already exists in target namespace
|
# Check if credential Secret already exists in target namespace
|
||||||
CRED_EXISTS=$(curl -sf -o /dev/null -w "%{http_code}" \
|
CRED_EXISTS=$(curl -s -o /dev/null -w "%{http_code}" \
|
||||||
--cacert "$CA_CERT" \
|
--cacert "$CA_CERT" \
|
||||||
-H "Authorization: Bearer ${SA_TOKEN}" \
|
-H "Authorization: Bearer ${SA_TOKEN}" \
|
||||||
"${K8S_API}/api/v1/namespaces/${CRED_NS}/secrets/${CRED_NAME}")
|
"${K8S_API}/api/v1/namespaces/${CRED_NS}/secrets/${CRED_NAME}" || echo "000")
|
||||||
|
|
||||||
# Skip if hash matches and credential Secret exists
|
# Skip if hash matches and credential Secret exists
|
||||||
if [ "$CONFIG_HASH" = "$EXISTING_HASH" ] && [ "$CRED_EXISTS" = "200" ]; then
|
if [ "$CONFIG_HASH" = "$EXISTING_HASH" ] && [ "$CRED_EXISTS" = "200" ]; then
|
||||||
@@ -466,44 +528,47 @@ extraDeploy:
|
|||||||
publicClient: false,
|
publicClient: false,
|
||||||
redirectUris: .redirectUris,
|
redirectUris: .redirectUris,
|
||||||
webOrigins: .webOrigins,
|
webOrigins: .webOrigins,
|
||||||
defaultClientScopes: .defaultClientScopes,
|
|
||||||
protocolMappers: (.protocolMappers // [])
|
protocolMappers: (.protocolMappers // [])
|
||||||
}')
|
} | with_entries(select(.value != null))')
|
||||||
|
|
||||||
# Check if client already exists
|
# Check if client already exists
|
||||||
EXISTING=$(curl -sf -H "Authorization: Bearer ${TOKEN}" \
|
EXISTING_RESPONSE=$(curl -s -H "Authorization: Bearer ${TOKEN}" \
|
||||||
"${KEYCLOAK_URL}/admin/realms/${REALM}/clients?clientId=${CLIENT_ID}" \
|
"${KEYCLOAK_URL}/admin/realms/${REALM}/clients?clientId=${CLIENT_ID}" || true)
|
||||||
| jq -r '.[0].id // empty')
|
EXISTING=$(echo "$EXISTING_RESPONSE" | jq -r '.[0].id // empty' 2>/dev/null || true)
|
||||||
|
|
||||||
if [ -n "$EXISTING" ]; then
|
if [ -n "$EXISTING" ]; then
|
||||||
echo " Updating existing Keycloak client (uuid: ${EXISTING})"
|
echo " Updating existing Keycloak client (uuid: ${EXISTING})"
|
||||||
HTTP_CODE=$(curl -sf -o /dev/null -w "%{http_code}" \
|
RESPONSE=$(curl -s -w "\n%{http_code}" \
|
||||||
-H "Authorization: Bearer ${TOKEN}" \
|
-H "Authorization: Bearer ${TOKEN}" \
|
||||||
-H "Content-Type: application/json" \
|
-H "Content-Type: application/json" \
|
||||||
-X PUT -d "$KC_CLIENT" \
|
-X PUT -d "$KC_CLIENT" \
|
||||||
"${KEYCLOAK_URL}/admin/realms/${REALM}/clients/${EXISTING}")
|
"${KEYCLOAK_URL}/admin/realms/${REALM}/clients/${EXISTING}" || true)
|
||||||
|
HTTP_CODE=$(echo "$RESPONSE" | tail -1)
|
||||||
|
RESPONSE_BODY=$(echo "$RESPONSE" | sed '$d')
|
||||||
if [ "$HTTP_CODE" != "204" ] && [ "$HTTP_CODE" != "200" ]; then
|
if [ "$HTTP_CODE" != "204" ] && [ "$HTTP_CODE" != "200" ]; then
|
||||||
echo " ERROR: Failed to update client '${CLIENT_ID}' (HTTP ${HTTP_CODE})"
|
echo " ERROR: Failed to update client '${CLIENT_ID}' (HTTP ${HTTP_CODE}): ${RESPONSE_BODY}"
|
||||||
annotate_secret "keycloak" "$CONFIG_NAME" "keycloak.forteapps.net/sync-status" "error"
|
annotate_secret "keycloak" "$CONFIG_NAME" "keycloak.forteapps.net/sync-status" "error"
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
CLIENT_UUID="$EXISTING"
|
CLIENT_UUID="$EXISTING"
|
||||||
else
|
else
|
||||||
echo " Creating new Keycloak client '${CLIENT_ID}'"
|
echo " Creating new Keycloak client '${CLIENT_ID}'"
|
||||||
HTTP_CODE=$(curl -sf -o /dev/null -w "%{http_code}" \
|
RESPONSE=$(curl -s -w "\n%{http_code}" \
|
||||||
-H "Authorization: Bearer ${TOKEN}" \
|
-H "Authorization: Bearer ${TOKEN}" \
|
||||||
-H "Content-Type: application/json" \
|
-H "Content-Type: application/json" \
|
||||||
-X POST -d "$KC_CLIENT" \
|
-X POST -d "$KC_CLIENT" \
|
||||||
"${KEYCLOAK_URL}/admin/realms/${REALM}/clients")
|
"${KEYCLOAK_URL}/admin/realms/${REALM}/clients" || true)
|
||||||
|
HTTP_CODE=$(echo "$RESPONSE" | tail -1)
|
||||||
|
RESPONSE_BODY=$(echo "$RESPONSE" | sed '$d')
|
||||||
if [ "$HTTP_CODE" != "201" ]; then
|
if [ "$HTTP_CODE" != "201" ]; then
|
||||||
echo " ERROR: Failed to create client '${CLIENT_ID}' (HTTP ${HTTP_CODE})"
|
echo " ERROR: Failed to create client '${CLIENT_ID}' (HTTP ${HTTP_CODE}): ${RESPONSE_BODY}"
|
||||||
annotate_secret "keycloak" "$CONFIG_NAME" "keycloak.forteapps.net/sync-status" "error"
|
annotate_secret "keycloak" "$CONFIG_NAME" "keycloak.forteapps.net/sync-status" "error"
|
||||||
continue
|
continue
|
||||||
fi
|
fi
|
||||||
# Fetch the newly created client's UUID
|
# Fetch the newly created client's UUID
|
||||||
CLIENT_UUID=$(curl -sf -H "Authorization: Bearer ${TOKEN}" \
|
CLIENT_UUID=$(curl -s -H "Authorization: Bearer ${TOKEN}" \
|
||||||
"${KEYCLOAK_URL}/admin/realms/${REALM}/clients?clientId=${CLIENT_ID}" \
|
"${KEYCLOAK_URL}/admin/realms/${REALM}/clients?clientId=${CLIENT_ID}" \
|
||||||
| jq -r '.[0].id')
|
| jq -r '.[0].id' || true)
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Sync credentials to target namespace
|
# Sync credentials to target namespace
|
||||||
|
|||||||
7
infra/values/base/passwordpusher-values.yaml
Normal file
7
infra/values/base/passwordpusher-values.yaml
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
image:
|
||||||
|
repository: docker.io/pglombardo/pwpush
|
||||||
|
tag: "release-1.51.0"
|
||||||
|
|
||||||
|
# Disable the bundled postgresql subchart — we run our own StatefulSet
|
||||||
|
postgresql:
|
||||||
|
enabled: false
|
||||||
3
infra/values/base/vaultwarden-values.yaml
Normal file
3
infra/values/base/vaultwarden-values.yaml
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
image:
|
||||||
|
tag: "1.36.0-alpine"
|
||||||
|
domain: "https://vaultwarden.forteapps.net"
|
||||||
50
infra/values/upc-dev/passwordpusher-values.yaml
Normal file
50
infra/values/upc-dev/passwordpusher-values.yaml
Normal file
@@ -0,0 +1,50 @@
|
|||||||
|
env:
|
||||||
|
PWP__HOST_DOMAIN: pwpush.forteapps.net
|
||||||
|
PWP__HOST_PROTOCOL: https
|
||||||
|
PWP__ENABLE_LOGINS: "true"
|
||||||
|
PWP__ALLOW_ANONYMOUS: "false"
|
||||||
|
PWP__SIGNUPS_ENABLED: "false"
|
||||||
|
PWP__MAIL_RAISE_DELIVERY_ERRORS: "false"
|
||||||
|
PWP__MAIL_SMTP_ADDRESS: smtp.office365.com
|
||||||
|
PWP__MAIL_SMTP_PORT: "587"
|
||||||
|
PWP__MAIL_SMTP_AUTHENTICATION: login
|
||||||
|
PWP__MAIL_SMTP_STARTTLS: "true"
|
||||||
|
PWP__MAIL_SMTP_DOMAIN: fortedigital.com
|
||||||
|
PWP__MAIL_SENDER: noreply@fortedigital.com
|
||||||
|
|
||||||
|
envFrom:
|
||||||
|
- secretRef:
|
||||||
|
name: passwordpusher-db-creds
|
||||||
|
- secretRef:
|
||||||
|
name: passwordpusher-smtp-creds
|
||||||
|
|
||||||
|
ingress:
|
||||||
|
enabled: true
|
||||||
|
className: traefik
|
||||||
|
annotations:
|
||||||
|
cert-manager.io/cluster-issuer: letsencrypt-prod
|
||||||
|
gethomepage.dev/enabled: "true"
|
||||||
|
gethomepage.dev/name: "PasswordPusher"
|
||||||
|
gethomepage.dev/description: "Share passwords securely with expiring links"
|
||||||
|
gethomepage.dev/group: "Security"
|
||||||
|
gethomepage.dev/icon: "passwordpusher"
|
||||||
|
gethomepage.dev/href: "https://pwpush.forteapps.net"
|
||||||
|
hosts:
|
||||||
|
- host: pwpush.forteapps.net
|
||||||
|
paths:
|
||||||
|
- path: /
|
||||||
|
pathType: Prefix
|
||||||
|
tls:
|
||||||
|
- secretName: passwordpusher-tls
|
||||||
|
hosts:
|
||||||
|
- pwpush.forteapps.net
|
||||||
|
|
||||||
|
resources:
|
||||||
|
requests:
|
||||||
|
cpu: 100m
|
||||||
|
memory: 256Mi
|
||||||
|
limits:
|
||||||
|
cpu: 500m
|
||||||
|
memory: 512Mi
|
||||||
|
|
||||||
|
replicaCount: 1
|
||||||
82
infra/values/upc-dev/vaultwarden-values.yaml
Normal file
82
infra/values/upc-dev/vaultwarden-values.yaml
Normal file
@@ -0,0 +1,82 @@
|
|||||||
|
adminToken:
|
||||||
|
existingSecret: "prod-db-creds"
|
||||||
|
existingSecretKey: "adminToken"
|
||||||
|
domain: "https://vaultwarden.forteapps.net"
|
||||||
|
signupsAllowed: false
|
||||||
|
resourceType: StatefulSet
|
||||||
|
database:
|
||||||
|
type: postgresql
|
||||||
|
host: vaultwarden-postgresql
|
||||||
|
port: "5432"
|
||||||
|
dbName: vaultwarden
|
||||||
|
existingSecret: prod-db-creds
|
||||||
|
existingSecretKey: DATABASE_URL
|
||||||
|
existingSecretUserKey: pgusername
|
||||||
|
existingSecretPasswordKey: pgpassword
|
||||||
|
ingress:
|
||||||
|
enabled: true
|
||||||
|
class: "traefik"
|
||||||
|
tls: true
|
||||||
|
tlsSecret: vaultwarden-tls
|
||||||
|
hostname: vaultwarden.forteapps.net
|
||||||
|
additionalAnnotations:
|
||||||
|
cert-manager.io/cluster-issuer: letsencrypt-prod
|
||||||
|
gethomepage.dev/enabled: "true"
|
||||||
|
gethomepage.dev/name: "VaultWarden"
|
||||||
|
gethomepage.dev/description: "Password management"
|
||||||
|
gethomepage.dev/group: "Security"
|
||||||
|
gethomepage.dev/icon: "vaultwarden"
|
||||||
|
gethomepage.dev/href: "https://vaultwarden.forteapps.net"
|
||||||
|
|
||||||
|
replicas: 1
|
||||||
|
# Multi-Attach error for volume "pvc-102ec9a4-dccd-4cba-bb4b-650f7d934c81" Volume is already used by pod(s) vaultwarden-7f568875c7-m9cgs
|
||||||
|
|
||||||
|
service:
|
||||||
|
sessionAffinity: ClientIP
|
||||||
|
sessionAffinityConfig:
|
||||||
|
clientIP:
|
||||||
|
timeoutSeconds: 10800
|
||||||
|
|
||||||
|
smtp:
|
||||||
|
host: smtp.office365.com
|
||||||
|
security: starttls
|
||||||
|
port: 587
|
||||||
|
authMechanism: "Login"
|
||||||
|
from: noreply@fortedigital.com
|
||||||
|
fromName: "Forte Bitwarden Administrator"
|
||||||
|
debug: true
|
||||||
|
existingSecret: prod-db-creds
|
||||||
|
username:
|
||||||
|
existingSecretKey: SMTP_USERNAME
|
||||||
|
password:
|
||||||
|
existingSecretKey: SMTP_PASSWORD
|
||||||
|
|
||||||
|
storage:
|
||||||
|
data:
|
||||||
|
name: "vaultwarden-data"
|
||||||
|
size: "5Gi"
|
||||||
|
class: ""
|
||||||
|
path: "/data"
|
||||||
|
keepPvc: true
|
||||||
|
accessMode: "ReadWriteOnce"
|
||||||
|
|
||||||
|
attachments:
|
||||||
|
name: "vaultwarden-files"
|
||||||
|
size: "5Gi"
|
||||||
|
class: ""
|
||||||
|
path: /files
|
||||||
|
keepPvc: true
|
||||||
|
accessMode: "ReadWriteOnce"
|
||||||
|
|
||||||
|
sso:
|
||||||
|
enabled: true
|
||||||
|
existingSecret: vaultwarden-oidc-credentials
|
||||||
|
authority: "https://id.forteapps.net/realms/forte"
|
||||||
|
scopes: "email profile"
|
||||||
|
onlySSO: true
|
||||||
|
pkce: true
|
||||||
|
signupsMatchEmail: true
|
||||||
|
clientId:
|
||||||
|
existingSecretKey: client-id
|
||||||
|
clientSecret:
|
||||||
|
existingSecretKey: client-secret
|
||||||
Reference in New Issue
Block a user