d25d482dc2
Publish CLI Package / publish-npm (push) Waiting to run
Publish Python SDK / publish-pypi (push) Waiting to run
Publish TypeScript SDK / publish-npm (push) Waiting to run
CI / Migrate Dev DB (push) Has been skipped
CI / Detect Version (push) Has been cancelled
CI / Migrate DB (push) Has been cancelled
CI / Build Dev ECR (./docker/app.Dockerfile, ECR_APP) (push) Has been cancelled
CI / Build Dev ECR (./docker/db.Dockerfile, ECR_MIGRATIONS) (push) Has been cancelled
CI / Build Dev ECR (./docker/pii.Dockerfile, ECR_PII) (push) Has been cancelled
CI / Build Dev ECR (./docker/realtime.Dockerfile, ECR_REALTIME) (push) Has been cancelled
CI / Deploy Trigger.dev (Dev) (push) Has been cancelled
CI / Build AMD64 (./docker/app.Dockerfile, ECR_APP, ghcr.io/simstudioai/simstudio) (push) Has been cancelled
CI / Build AMD64 (./docker/db.Dockerfile, ECR_MIGRATIONS, ghcr.io/simstudioai/migrations) (push) Has been cancelled
CI / Build AMD64 (./docker/pii.Dockerfile, ECR_PII, ghcr.io/simstudioai/pii) (push) Has been cancelled
CI / Build AMD64 (./docker/realtime.Dockerfile, ECR_REALTIME, ghcr.io/simstudioai/realtime) (push) Has been cancelled
CI / Build ARM64 (GHCR Only) (./docker/app.Dockerfile, ghcr.io/simstudioai/simstudio) (push) Has been cancelled
CI / Build ARM64 (GHCR Only) (./docker/db.Dockerfile, ghcr.io/simstudioai/migrations) (push) Has been cancelled
CI / Build ARM64 (GHCR Only) (./docker/pii.Dockerfile, ghcr.io/simstudioai/pii) (push) Has been cancelled
CI / Build ARM64 (GHCR Only) (./docker/realtime.Dockerfile, ghcr.io/simstudioai/realtime) (push) Has been cancelled
CI / Create GHCR Manifests (ghcr.io/simstudioai/migrations) (push) Has been cancelled
CI / Create GHCR Manifests (ghcr.io/simstudioai/pii) (push) Has been cancelled
CI / Create GHCR Manifests (ghcr.io/simstudioai/realtime) (push) Has been cancelled
CI / Create GHCR Manifests (ghcr.io/simstudioai/simstudio) (push) Has been cancelled
CI / Check Docs Changes (push) Has been cancelled
CI / Process Docs (push) Has been cancelled
CI / Create GitHub Release (push) Has been cancelled
CI / Test and Build (push) Has been cancelled
179 lines
4.7 KiB
YAML
179 lines
4.7 KiB
YAML
suite: NetworkPolicy — ingressFrom + telemetry egress + egress shape
|
|
templates:
|
|
- networkpolicy.yaml
|
|
release:
|
|
name: t
|
|
namespace: sim
|
|
defaults: &defaults
|
|
app.env.BETTER_AUTH_SECRET: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
|
app.env.ENCRYPTION_KEY: xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
|
|
app.env.INTERNAL_API_SECRET: x
|
|
app.env.CRON_SECRET: x
|
|
postgresql.auth.password: xxxxxxxx
|
|
networkPolicy.enabled: true
|
|
ingress.enabled: true
|
|
ingress.app.host: a.test
|
|
ingress.realtime.host: b.test
|
|
|
|
tests:
|
|
- it: does not render when networkPolicy.enabled=false
|
|
set:
|
|
<<: *defaults
|
|
networkPolicy.enabled: false
|
|
asserts:
|
|
- hasDocuments: { count: 0 }
|
|
|
|
- it: default ingressFrom is the explicit any-source peer (single empty peer)
|
|
set:
|
|
<<: *defaults
|
|
documentIndex: 0
|
|
asserts:
|
|
- equal:
|
|
path: spec.ingress[2].from
|
|
value:
|
|
- {}
|
|
|
|
- it: ingressFrom is overridable to a namespace selector
|
|
set:
|
|
<<: *defaults
|
|
networkPolicy.ingressFrom:
|
|
- namespaceSelector:
|
|
matchLabels:
|
|
kubernetes.io/metadata.name: ingress-nginx
|
|
documentIndex: 0
|
|
asserts:
|
|
- equal:
|
|
path: spec.ingress[2].from
|
|
value:
|
|
- namespaceSelector:
|
|
matchLabels:
|
|
kubernetes.io/metadata.name: ingress-nginx
|
|
|
|
- it: app NetworkPolicy includes telemetry egress (ports 4317 + 4318) when telemetry enabled (round-5 fix)
|
|
set:
|
|
<<: *defaults
|
|
telemetry.enabled: true
|
|
documentIndex: 0
|
|
asserts:
|
|
- contains:
|
|
path: spec.egress
|
|
content:
|
|
to:
|
|
- podSelector:
|
|
matchLabels:
|
|
app.kubernetes.io/name: sim
|
|
app.kubernetes.io/instance: t
|
|
app.kubernetes.io/component: telemetry
|
|
ports:
|
|
- protocol: TCP
|
|
port: 4317
|
|
- protocol: TCP
|
|
port: 4318
|
|
|
|
- it: realtime NetworkPolicy includes telemetry egress when telemetry enabled
|
|
set:
|
|
<<: *defaults
|
|
telemetry.enabled: true
|
|
documentIndex: 1
|
|
asserts:
|
|
- contains:
|
|
path: spec.egress
|
|
content:
|
|
to:
|
|
- podSelector:
|
|
matchLabels:
|
|
app.kubernetes.io/name: sim
|
|
app.kubernetes.io/instance: t
|
|
app.kubernetes.io/component: telemetry
|
|
ports:
|
|
- protocol: TCP
|
|
port: 4317
|
|
- protocol: TCP
|
|
port: 4318
|
|
|
|
- it: app NetworkPolicy allows ingress from cron pods when cronjobs.enabled=true
|
|
set:
|
|
<<: *defaults
|
|
documentIndex: 0
|
|
asserts:
|
|
- contains:
|
|
path: spec.ingress
|
|
content:
|
|
from:
|
|
- podSelector:
|
|
matchLabels:
|
|
app.kubernetes.io/name: sim
|
|
app.kubernetes.io/instance: t
|
|
simstudio.ai/component-group: cronjob
|
|
ports:
|
|
- protocol: TCP
|
|
port: 3000
|
|
|
|
- it: cron→app ingress rule is omitted when cronjobs.enabled=false
|
|
set:
|
|
<<: *defaults
|
|
cronjobs.enabled: false
|
|
documentIndex: 0
|
|
asserts:
|
|
- notContains:
|
|
path: spec.ingress
|
|
content:
|
|
from:
|
|
- podSelector:
|
|
matchLabels:
|
|
app.kubernetes.io/name: sim
|
|
app.kubernetes.io/instance: t
|
|
simstudio.ai/component-group: cronjob
|
|
ports:
|
|
- protocol: TCP
|
|
port: 3000
|
|
|
|
- it: telemetry collector NetworkPolicy renders when telemetry.enabled=true
|
|
set:
|
|
<<: *defaults
|
|
telemetry.enabled: true
|
|
documentIndex: 3
|
|
asserts:
|
|
- equal:
|
|
path: kind
|
|
value: NetworkPolicy
|
|
- equal:
|
|
path: metadata.name
|
|
value: t-sim-otel-collector
|
|
|
|
- it: networkPolicy.egress (custom rules) are appended to the app NetworkPolicy
|
|
set:
|
|
<<: *defaults
|
|
networkPolicy.egress:
|
|
- to: []
|
|
ports:
|
|
- protocol: TCP
|
|
port: 5432
|
|
documentIndex: 0
|
|
asserts:
|
|
- contains:
|
|
path: spec.egress
|
|
content:
|
|
to: []
|
|
ports:
|
|
- protocol: TCP
|
|
port: 5432
|
|
|
|
- it: networkPolicy.egress (custom rules) are appended to the realtime NetworkPolicy
|
|
set:
|
|
<<: *defaults
|
|
networkPolicy.egress:
|
|
- to: []
|
|
ports:
|
|
- protocol: TCP
|
|
port: 5432
|
|
documentIndex: 1
|
|
asserts:
|
|
- contains:
|
|
path: spec.egress
|
|
content:
|
|
to: []
|
|
ports:
|
|
- protocol: TCP
|
|
port: 5432
|