Images and artifact delivery

  • Deliver packaged dependencies through per-Pod ephemeral or PV-backed storage, with reuse and failure tradeoffs.
Diagram phase
100%

Current · image cards are stored inputs · init containers copy files · cylinders are volumes

IMAGE INPUTS · release-selected contentDirect · repeat assembly for each newPodIL · repeat assembly for each new PodCurrent: images supply each Pod’s assembled filesSelect imageCopy / mount filesselect init imageselect init imageselect init imageselect init imagecopy filescopy filesmount filesmount filesselect app imageselect app imagemountmountAn init container copies Java and Tomcat from the runtime image into a volume for each new Pod. The init container copies these files into the Pod volume. OCI IMAGEShared runtimeJDK / TomcatThe application entrypoints expand the product WAR, overlay files, move JDBC/UCP libraries and write Tomcat/JNDI configuration. Immutable shared payloads therefore need separate per-Pod writable runtime/config/work paths. Each deployment selects an application image compatible with its init inputs and mounted files. OCI IMAGESApplication WAR+ settingsDirect libraries and packaged SMS/APIGW dependencies are delivered to the OBRH deployment. Its init container copies the selected libraries into the Pod. OCI IMAGEDirect librariesSMS/APIGW depsIL selects common and additional library images as delivery inputs. Its init containers copy the selected library files into the Pod. OCI IMAGESIL dependencylibrariesGroups the regular, ordered init-container executions selected by the Direct chart. Each executes its selected image, copies or prepares files and exits. Init success is a startup dependency. Image selection is different from the file bytes written to emptyDir.INIT CONTAINERSCopy / preparethen exitRuntime and JAR emptyDir volumes repeat assembly for replacement Pods. Same-Pod application restart can retain files; the inspected WEB-INF-exists shortcut is not a release-digest validation contract. Init containers write these files and the consumer mounts them. A restart within the same Pod and replacement with a new Pod have different volume lifetimes.emptyDirRuntime + JARsAn artifacts PVC already exists separately from the runtime/JAR emptyDir volumes. Selected PV declarations use hostPath, ReadWriteMany and Retain. These declarations do not establish cross-node shared storage or a versioned release manifest. The proposal improves publication identity and rollback compatibility rather than merely adding a PVC. This is a separate mounted delivery input, not a claim that the PVC is copied through the runtime emptyDir. Its content/version must match the release.EXISTING PVCExternal artifactsThe Direct deployment selects an application image and consumes the prepared emptyDir files plus separately mounted external artifacts. This is the delivery endpoint. Runtime internals and request invocation belong to their own architecture views.POD CONSUMERDirect deploymentGroups the regular init executions selected for IL; each runs its selected image and completes before normal application startup. Common and selected IL library inputs must form a tested release.INIT CONTAINERSCopy / preparethen exitRuntime and JAR emptyDir volumes repeat assembly for replacement Pods. Same-Pod application restart can retain files; the inspected WEB-INF-exists shortcut is not a release-digest validation contract. Warm-node image availability does not populate this new emptyDir; copy/extraction can still repeat.emptyDirRuntime + JARsAn artifacts PVC already exists separately from the runtime/JAR emptyDir volumes. Selected PV declarations use hostPath, ReadWriteMany and Retain. These declarations do not establish cross-node shared storage or a versioned release manifest. The proposal improves publication identity and rollback compatibility rather than merely adding a PVC. Its selected override/extensibility inputs must remain compatible with the IL release.EXISTING PVCExternal artifactsThe IL deployment selects its application image and consumes its own prepared files and the external artifact mount. This delivery view does not expand the application into processes or internal code modules.POD CONSUMERIL deploymentselect init imageselect init imageselect init imageselect init imagecopy filescopy filesmount filesmount filesselect app imageselect app imagemountmount

Select a component to trace its direct connections. Drag to pan · Ctrl + wheel or pinch to zoom.

  • Image inputs: shared runtime, application files, and Direct or IL dependencies. Direct includes packaged SMS/APIGW dependencies.
  • Per new Pod: regular init containers copy files into its own ephemeral emptyDir, then exit. The deployment consumes these files and its separate external-artifacts PVC mount.
  • Image selection chooses what executes; copy/mount arrows carry or expose file bytes.
  • A cached image avoids some transfers; it does not avoid each new Pod’s copy/extraction work.
Images and packaged delivery inputs

Images and packaged delivery inputs

Kubernetes core/v1, apps/v1 and batch/v1 · Docker/OCI delivery concepts

What reaches each Pod

  • Application images supply the WAR, settings and launch helpers.
  • Init containers copy Java, Tomcat and dependency files into the Pod’s emptyDir.
  • A replacement Pod repeats these copies. External artifacts arrive on a separate PVC.

Packaged SMS/APIGW dependencies

  • Direct receives SMS/APIGW dependencies through its library image.
  • The proposed CI build versions these libraries alongside the Direct adapters and verifies the local calls before packaging.

What an image cache saves

  • Keep stable inputs early in the Dockerfile so a change to application settings can reuse the runtime layers.
  • A warm node can skip downloading layers. Each new Pod still copies the runtime files into its own volume.
  • Measure image transfer, file preparation and readiness separately.

Prepare files at startup

  • Package shared libraries in an image. An init container copies them into a volume before the application starts.
  • When reusing expanded files, verify their release identity before loading them.
Package dependency files · Dockerfile fragmentdockerfile
# Illustrative dependency carrier. CI supplies the selected library files.
ARG OS_IMAGE
FROM ${OS_IMAGE}
COPY libraries/ /payload/libraries/
Check an expanded WAR · shell fragmentbash
#!/bin/sh
# Illustrative expansion step. The application path is on a writable Pod volume.
set -eu
: "${APP_DIR:?set the application directory}"
if [ ! -d "$APP_DIR/WEB-INF" ]; then
  mkdir -p "$APP_DIR"
  (cd "$APP_DIR" && jar -xf /app/service.war)
fi
# A failed extraction can already have created WEB-INF.
# Verify release identity and completeness before reusing the tree.
Copy a runtime image into emptyDir · Pod fragmentyaml
# Pod spec fragment. The two image references are placeholders.
# The carrier image contains sh, cp and /payload/runtime.
volumes:
  - name: runtime
    emptyDir: {}
initContainers:
  - name: copy-runtime
    image: example.invalid/runtime-carrier:r1
    command: ["sh", "-ec", "cp -R /payload/runtime/. /work/"]
    volumeMounts:
      - {name: runtime, mountPath: /work}
containers:
  - name: application
    image: example.invalid/service:r1
    volumeMounts:
      - {name: runtime, mountPath: /runtime}
# Set volume permissions for the image users and preserve required file modes.

Reduce repeated startup work

  • Build and validate reusable security dependencies plus Direct adapters before changing how they are delivered.
  • Consider stable Java/Tomcat layers and pre-expanded, versioned application files in immutable images; adjust mounts that would hide those files.
  • Generate only Pod-specific writable configuration/work state at startup.
  • Compare cold/warm pulls, copy/extraction, JVM initialization and readiness before selecting more init steps or a shared artifact store.
  • Rebuild and test affected consumers when shared runtime/security dependencies change.
  • The complete product CMC-OBRH WAR, including Camel, is an input to both separate Direct and IL assemblies.
  • Direct-specific and IL-specific extension inputs are separate; selected SMS/APIGW compatibility components are shared inputs to both flavours.
  • Jenkins/generated Gradle/Helm and supporting source folders do not by themselves prove complete affected-consumer rebuild selection.
  • The sampled WAR carrier adds payload to /scratch/wars/; exact loading and archive/classloader mechanics remain unresolved.
Artifact storage choices

Artifact storage choices

Kubernetes core/v1, apps/v1 and batch/v1 · Docker/OCI delivery concepts

Choose the prepared-file lifetime

  • Ephemeral: every new Pod prepares its own files. A restart within that Pod can retain them.
  • Persistent: compatible consumers can reuse immutable published versions, subject to backend, access-mode and topology constraints.
  • Init containers and preparation Jobs populate storage; they are not storage types.
  • Current already combines runtime/JAR emptyDir with an external-artifacts PVC. The proposal changes publication, compatibility and reuse.

Evaluate the mechanisms in their worked views

Question Worked example
What repeats for each new Pod? Ordered init copies, mounts, validation and failed-init/replacement cases
What does a release actually identify? R1/R2 manifests, common/V1 reuse, read-only paths and retained rollback inputs
When may consumers start? Stage, verify, publish, complete the Job and explicitly gate deployment
How far can a storage failure spread? Shared-backend versus independent domain/cluster storage