Skip to content

feat: support per-route container image override#47

Merged
dcruver merged 2 commits intocodice:mainfrom
dcruver:feature/per-route-image
Feb 24, 2026
Merged

feat: support per-route container image override#47
dcruver merged 2 commits intocodice:mainfrom
dcruver:feature/per-route-image

Conversation

@dcruver
Copy link
Collaborator

@dcruver dcruver commented Feb 21, 2026

Summary

Adds an optional spec.image field to the IntegrationRoute CRD, allowing individual routes to specify their own container image instead of using the cluster-wide default.

Motivation

Currently, all IntegrationRoutes in a keip cluster share the same container image defined in keip-controller-props. This means if you have multiple applications with different classpaths (e.g., different custom beans or dependencies), you must either:

  1. Bundle everything into a single fat image
  2. Run separate keip clusters

Neither is ideal. Per-route images let different applications coexist naturally in the same cluster.

Changes

  • CRD (operator/crd/crd.yaml): Added spec.image (optional string) to v1alpha2 schema
  • Webhook (webapp/core/sync.py): Resolve image from spec.image with fallback to global INTEGRATION_CONTAINER_IMAGE
  • Tests (webapp/core/test/test_sync.py): Two new tests verifying override and default fallback

Usage

apiVersion: keip.codice.org/v1alpha2
kind: IntegrationRoute
metadata:
  name: my-custom-route
spec:
  image: "registry.example.com/my-app:1.0"
  routeConfigMap: my-route-xml
  replicas: 1

When spec.image is omitted, behavior is unchanged — the global default from the controller ConfigMap is used.

Backward Compatibility

Fully backward compatible. The field is optional with no default in the CRD schema. Existing IntegrationRoutes without spec.image continue to work exactly as before.

Add optional spec.image field to IntegrationRoute CRD. When set, the
route deployment uses the specified container image instead of the
cluster-wide default from keip-controller-props ConfigMap.

This enables multiple applications with different classpaths to coexist
in the same keip cluster without requiring separate controller instances.

Changes:
- CRD: add spec.image (string, optional) to v1alpha2 schema
- Webhook: resolve image from spec.image with fallback to global default
- Tests: verify per-route override and default fallback behavior
CI verify-versions was failing because both artifacts had changes
but their version tags were already released.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@dcruver dcruver merged commit 1adfe54 into codice:main Feb 24, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants