Repository navigation
Minor manifests fixes #1349
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Minor manifests fixes #1349
Changes from all commits
0e287b3
5132c44
30553cc
4b1e1da
7d0ad2f
889c180
76f254c
e57cf7b
7cc2414
0520e8a
aea585f
9a3d893
cf70063
913736f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,7 +1,7 @@ | ||
| version: "3.4" | ||
| services: | ||
| nginx: | ||
| image: "ddmal/nginx:${DOCKER_TAG}" | ||
| image: "ghcr.io/ddmal/nginx:${DOCKER_TAG}" | ||
| command: /run/start | ||
| depends_on: | ||
| - celery | ||
|
|
@@ -18,9 +18,13 @@ services: | |
| - "9002:9002" | ||
| volumes: | ||
| - "resources:/rodan/data" | ||
| # Local-only override: pass the real request scheme instead of the hardcoded | ||
| # `X-Scheme https` baked into the prod image, so DRF emits http:// URLs over | ||
| # plain-HTTP local dev (Django's SECURE_PROXY_SSL_HEADER trusts X-Scheme). | ||
| - "./nginx/config/rodan.local.conf:/etc/nginx/sites-available/rodan.conf" | ||
|
|
||
| rodan-main: | ||
| image: "ddmal/rodan-main:${DOCKER_TAG}" | ||
| image: "ghcr.io/ddmal/rodan-main:${DOCKER_TAG}" | ||
| healthcheck: | ||
| test: | ||
| [ | ||
|
|
@@ -31,7 +35,7 @@ services: | |
| timeout: "5s" | ||
| retries: 2 | ||
| start_period: "2m" | ||
| command: bash -c "tail -f /dev/null" | ||
| command: /run/start | ||
| environment: | ||
| TZ: America/Toronto | ||
| SERVER_HOST: localhost | ||
|
|
@@ -48,19 +52,19 @@ services: | |
| - "./rodan-main/code:/code/Rodan" | ||
|
|
||
| rodan-client: | ||
| image: "ddmal/rodan-client:${DOCKER_TAG}" | ||
| image: "ghcr.io/ddmal/rodan-client:${DOCKER_TAG}" | ||
| volumes: | ||
| - "./rodan-client/code:/code" | ||
| - "./rodan-client/config/configuration.json:/client/configuration.json" | ||
|
|
||
| iipsrv: | ||
| image: "ddmal/iipsrv:${DOCKER_TAG}" | ||
| image: "ghcr.io/ddmal/iipsrv:${DOCKER_TAG}" | ||
| volumes: | ||
| - "resources:/rodan/data" | ||
|
|
||
| celery: | ||
| image: "ddmal/rodan-main:${DOCKER_TAG}" | ||
| command: bash -c "tail -f /dev/null" | ||
| image: "ghcr.io/ddmal/rodan-main:${DOCKER_TAG}" | ||
| command: /run/start-celery | ||
| environment: | ||
| TZ: America/Toronto | ||
| SERVER_HOST: localhost | ||
|
|
@@ -70,12 +74,12 @@ services: | |
| [ | ||
| "CMD", | ||
| "celery", | ||
| "inspect", | ||
| "ping", | ||
| "-A", | ||
| "rodan", | ||
| "--workdir", | ||
| "/code/Rodan", | ||
| "inspect", | ||
| "ping", | ||
| "-d", | ||
| "celery@celery" | ||
| ] | ||
|
|
@@ -95,7 +99,7 @@ services: | |
| - "./rodan-main/code:/code/Rodan" | ||
|
|
||
| py3-celery: | ||
| image: "ddmal/rodan-python3-celery:${DOCKER_TAG}" | ||
| image: "ghcr.io/ddmal/rodan-python3-celery:${DOCKER_TAG}" | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🩺 Stability & Availability | 🟠 Major | ⚡ Quick win Start
📍 Affects 2 files
🤖 Prompt for AI Agents |
||
| command: bash -c "tail -f /dev/null" | ||
| environment: | ||
| TZ: America/Toronto | ||
|
|
@@ -114,8 +118,8 @@ services: | |
| - "./rodan-main/code:/code/Rodan" | ||
|
|
||
| gpu-celery: | ||
| image: "ddmal/rodan-gpu-celery:${DOCKER_TAG}" | ||
| command: bash -c "tail -f /dev/null" | ||
| image: "ghcr.io/ddmal/rodan-gpu-celery:${DOCKER_TAG}" | ||
| command: /run/start-celery | ||
| environment: | ||
| TZ: America/Toronto | ||
| SERVER_HOST: localhost | ||
|
|
@@ -143,7 +147,7 @@ services: | |
| - postgres | ||
|
|
||
| postgres: | ||
| image: "ddmal/postgres-plpython:${DOCKER_TAG}" | ||
| image: "ghcr.io/ddmal/postgres-plpython:${DOCKER_TAG}" | ||
| healthcheck: | ||
| test: [ "CMD-SHELL", "pg_isready", "-U", "postgres" ] | ||
| interval: 10s | ||
|
|
@@ -153,7 +157,11 @@ services: | |
| - ./scripts/local.env | ||
|
|
||
| rabbitmq: | ||
| image: "rabbitmq:alpine" | ||
| # Pinned to the 3.13 line to match production (3.13.7). RabbitMQ 4.x disables the | ||
| # `transient_nonexcl_queues` feature by default, which Celery's pidbox/reply/event | ||
| # queues (and `celery inspect`) declare — an unpinned `rabbitmq:alpine` now resolves | ||
| # to 4.x and breaks the workers with "Feature transient_nonexcl_queues is deprecated". | ||
| image: "rabbitmq:3.13-alpine" | ||
| healthcheck: | ||
| test: [ "CMD", "rabbitmq-diagnostics", "-q", "ping" ] | ||
| interval: "30s" | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -11,6 +11,24 @@ RUN apk add --no-cache \ | |
|
|
||
| RUN wget https://github.com/ruven/iipsrv/archive/refs/heads/master.zip && unzip master.zip | ||
| WORKDIR /iipsrv-master | ||
| # Patch upstream OpenJPEG 8-bit decode bug: the mask for 8-bit output data is | ||
| # 0x000000f (4-bit / low nibble only), which renders every 8-bit JP2 ~32x too | ||
| # dark. It must be 0x000000ff (full 8-bit byte). See src/OpenJPEGImage.cc. | ||
| RUN sed -i 's/& 0x000000f)/\& 0x000000ff)/' src/OpenJPEGImage.cc \ | ||
| && grep -q '& 0x000000ff)' src/OpenJPEGImage.cc | ||
|
Comment on lines
+17
to
+18
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🎯 Functional Correctness | 🟠 Major | ⚡ Quick win Make the mask patch match the downloaded source. The Dockerfile downloads upstream 🧰 Tools🪛 Checkov (3.3.17)[low] 1-55: Ensure that HEALTHCHECK instructions have been added to container images (CKV_DOCKER_2) [low] 1-55: Ensure that a user for the container has been created (CKV_DOCKER_3) 🤖 Prompt for AI Agents |
||
| # Patch upstream OpenJPEG region-clamp bug in OpenJPEGImage::process(). | ||
| # w0/h0 are END coordinates passed to | ||
| # opj_set_decode_area(codec, img, start_x, start_y, end_x, end_y), | ||
| # but the overrun clamp treats them as widths (x0 + w0) and reassigns | ||
| # w0 = image_widths[0] - x0. For any tile whose x0 > width/2 this makes | ||
| # end_x < start_x, so OpenJPEG gets a negative decode width and errors out | ||
| # -> the right/bottom half of every image 404s (and the boundary band | ||
| # garbles) when zooming. w0/h0 must be clamped to the image dimensions | ||
| # directly, not offset by x0/y0. | ||
| RUN sed -i 's/if( x0 + w0 > image_widths\[0\][[:space:]]*) w0 = image_widths\[0\][[:space:]]*- x0;/if( w0 > image_widths[0] ) w0 = image_widths[0];/' src/OpenJPEGImage.cc \ | ||
| && sed -i 's/if( y0 + h0 > image_heights\[0\][[:space:]]*) h0 = image_heights\[0\][[:space:]]*- y0;/if( h0 > image_heights[0] ) h0 = image_heights[0];/' src/OpenJPEGImage.cc \ | ||
| && grep -q 'if( w0 > image_widths\[0\] ) w0 = image_widths\[0\];' src/OpenJPEGImage.cc \ | ||
| && grep -q 'if( h0 > image_heights\[0\] ) h0 = image_heights\[0\];' src/OpenJPEGImage.cc | ||
| RUN ./autogen.sh | ||
| RUN ./configure --enable-openjpeg | ||
| RUN make | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -18,6 +18,16 @@ spec: | |
| spec: | ||
| imagePullSecrets: | ||
| - name: ghcr-pull-secret | ||
| # Pinned to Rodan's GPU node for its memory headroom (68 GiB): create_diva on a p99 | ||
| # (~120 Mpx) image peaks ~3.3 GB and 3 concurrent p90 images ~6.2 GB, more than the shared | ||
| # nodes have free. Tolerates the GPU taint but does NOT use the nvidia RuntimeClass, so | ||
| # gpu-celery stays the only GPU consumer on the node. | ||
| nodeSelector: | ||
| kubernetes.io/hostname: k3s-gpu-node-2 | ||
|
Comment on lines
+25
to
+26
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🩺 Stability & Availability | 🟠 Major | 🏗️ Heavy lift Provide a scheduling fallback for both Celery queues. Both single-replica workers now require
🧰 Tools🪛 Checkov (3.3.17)[medium] 4-67: Containers should not run with allowPrivilegeEscalation (CKV_K8S_20) [low] 4-67: Apply security context to your containers (CKV_K8S_30) [low] 4-67: Minimize the admission of containers with the NET_RAW capability (CKV_K8S_28) [low] 4-67: Image should use digest (CKV_K8S_43) [low] 4-67: Image Pull Policy should be Always (CKV_K8S_15) [low] 4-67: Minimize the admission of containers with capabilities assigned (CKV_K8S_37) [low] 4-67: Apply security context to your pods and containers (CKV_K8S_29) [low] 4-67: Use read-only filesystem for containers where possible (CKV_K8S_22) [low] 4-67: Readiness Probe Should be Configured (CKV_K8S_9) [medium] 4-67: Minimize the admission of root containers (CKV_K8S_23) [low] 4-67: Containers should run as a high UID to avoid host conflict (CKV_K8S_40) [low] 4-67: Ensure that the seccomp profile is set to docker/default or runtime/default (CKV_K8S_31) [low] 4-67: Prefer using secrets as files over secrets as environment variables (CKV_K8S_35) [low] 4-67: Ensure that Service Account Tokens are only mounted where necessary (CKV_K8S_38) 🪛 Trivy (0.74.0)[error] 18-67: Default security context configured deployment celery in rodan namespace is using the default security context, which allows root privileges Rule: KSV-0118 (IaC/Kubernetes) 📍 Affects 2 files
🤖 Prompt for AI Agents |
||
| tolerations: | ||
| - key: nvidia.com/gpu | ||
| operator: Exists | ||
| effect: NoSchedule | ||
| containers: | ||
| - name: celery | ||
| image: ghcr.io/ddmal/rodan-main:nightly | ||
|
|
@@ -43,13 +53,14 @@ spec: | |
| periodSeconds: 60 | ||
| timeoutSeconds: 45 | ||
| failureThreshold: 3 | ||
| # Idle ~0.4Gi; limit covers 3 concurrent large create_diva conversions (concurrency=3). | ||
| resources: | ||
| requests: | ||
| cpu: "500m" | ||
| memory: "2Gi" | ||
| cpu: "250m" | ||
| memory: "1Gi" | ||
| limits: | ||
| cpu: "4" | ||
| memory: "12Gi" | ||
| memory: "10Gi" | ||
| volumes: | ||
| - name: resources | ||
| persistentVolumeClaim: | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🩺 Stability & Availability | 🟠 Major | ⚡ Quick win
Stop when the Neon wrapper copy fails.
If
docker cpfails anddocker rmsucceeds, this recipe reports success and prints “neon_wrapper ready.” Line 63 has already removed the existing wrapper. Make container cleanup preserve the copy command’s failure status somake runstops before starting without the wrapper.🤖 Prompt for AI Agents