Skip to content
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.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@
# ZITADEL (8080) and Dex (5556); only the namespace itself and the CNPG
# operator reach the database. Egress: the namespace itself, the API server
# (CNPG instance manager), R2 for backups, ZITADEL's public name for Dex's
# connector, and the business site's SES SMTP endpoint for ZITADEL's
# connector, the platform Dex, through which ZITADEL signs its administrator
# in with GitHub, and the business site's SES SMTP endpoint for ZITADEL's
# invitation and recovery mail (platform#5400).
apiVersion: cilium.io/v2
kind: CiliumNetworkPolicy
Expand Down Expand Up @@ -50,6 +51,12 @@ spec:
- ports:
- port: "443"
protocol: TCP
- toFQDNs:
- matchName: dex.platform.devantler.tech
toPorts:
- ports:
- port: "443"
protocol: TCP
- toFQDNs:
- matchName: email-smtp.eu-central-1.amazonaws.com
toPorts:
Expand Down
256 changes: 249 additions & 7 deletions k8s/providers/hetzner/apps/customer-identity/cron-job-setup.yaml

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# The platform Dex's shared client secret (OpenBao infrastructure/oidc/dex),
# which ZITADEL presents when it signs its administrator in with GitHub through
# that Dex. Only the setup CronJob mounts it, to keep ZITADEL's identity
# provider configured (cron-job-setup.yaml).
apiVersion: external-secrets.io/v1
kind: ExternalSecret
metadata:
name: platform-dex-client
namespace: customer-identity
spec:
refreshInterval: 1h
secretStoreRef:
name: openbao
kind: ClusterSecretStore
target:
name: platform-dex-client
creationPolicy: Owner
data:
- secretKey: client-secret # checkov:skip=CKV_SECRET_6:names the key in the synced Secret; the value lives in OpenBao
remoteRef:
key: infrastructure/oidc/dex
property: client-secret
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,12 @@ spec:
scopes:
- profile
- email
# Customers live in ZITADEL's "Customers" organization, which
# the setup CronJob creates. This scope signs them in under
# its login policy (password and MFA) and admits no one else.
# Without it they would get the default organization's
# policy, which sends its administrator straight to GitHub.
- urn:zitadel:iam:org:domain:primary:customers.accounts.devantler.tech
getUserInfo: true
insecureSkipEmailVerified: false
insecureEnableGroups: false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ resources:
- external-secret-smtp.yaml
- password-first-admin.yaml
- external-secret-first-admin.yaml
- external-secret-platform-dex-client.yaml
- helm-repository.yaml
- helm-release.yaml
# The portal's customer Dex.
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Prod-only: ZITADEL (accounts.devantler.tech, apps/customer-identity) signs
# its administrator in with GitHub through this Dex, which it uses as a generic
# OIDC identity provider (business-site#302). Its Login V1 callback joins the
# shared client's redirect URIs; the customer-identity setup CronJob reads that
# client's secret from OpenBao (infrastructure/oidc/dex). The test stops the
# build if the shared client is no longer the first entry.
- op: test
path: /spec/values/config/staticClients/0/id
value: public-client
- op: add
path: /spec/values/config/staticClients/0/redirectURIs/-
value: https://accounts.devantler.tech/ui/login/login/externalidp/callback
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,14 @@ patches:
- path: kyverno/patches/allow-sigstore-cache-eviction.yaml
# Prod-only: run Dex on the source-built, signed distribution — see file.
- path: dex/patches/run-source-built-image.yaml
# Prod-only: let ZITADEL's administrator sign in through Dex — see file.
- path: dex/patches/allow-zitadel-sign-in.yaml
target:
group: helm.toolkit.fluxcd.io
version: v2
kind: HelmRelease
name: dex
namespace: dex
# Prod-only fail-closed WireGuard encryption (egress strict mode) — see file.
- path: cilium/patches/enforce-wireguard-strict-mode.yaml
# Require relay replicas to use separate nodes in prod; local retains soft spread.
Expand Down
4 changes: 2 additions & 2 deletions scripts/validate-eks-ci-role-policy/approved-surface.txt
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,11 @@ helm.toolkit.fluxcd.io/v2|HelmRelease|cnpg-system|plugin-barman-cloud 74682cb45a

helm.toolkit.fluxcd.io/v2|HelmRelease|crossplane-system|crossplane fb717f7c9adb21b0f772e6a84554900e568a2675c91d375d1bb6ee76c2a0b1f3

helm.toolkit.fluxcd.io/v2|HelmRelease|customer-identity|customer-dex 1733d0b05966c1c28a4c6a1c1caa221208958b04d36bdd6d2e1672ce0587c795
helm.toolkit.fluxcd.io/v2|HelmRelease|customer-identity|customer-dex 55a9ceabb55c712138a754c1666cf9e55b62b47357e3ac3cddea423a17531051

helm.toolkit.fluxcd.io/v2|HelmRelease|customer-identity|zitadel eeb9881018664637cdefc9c5c0afd6953aa958e5dbfbc9cd8c5d521501e52431

helm.toolkit.fluxcd.io/v2|HelmRelease|dex|dex e2cbe6e6b5ace19ebded8d0e75f508277dd450c079ed51062d13649e148904b9
helm.toolkit.fluxcd.io/v2|HelmRelease|dex|dex 1a1e8181ff71a06313611577a55fe9b3cb356a1071139b3d852dcaa42dafe972

helm.toolkit.fluxcd.io/v2|HelmRelease|external-dns|external-dns 107eaf8ad3d74abff5c6b1c6d7ca1b49ac75829fe425672f81cdc1e799457511

Expand Down
Loading