Files
floci/docker/Dockerfile.compat
T
Jason van Zyl 42d94c62ee ci: add reusable JVM and native image publishing (#1936)
* ci: add reusable image publishing

Provide a workflow_call contract that builds native amd64 and arm64 artifacts and publishes native and compat multi-architecture images for an exact caller-selected source revision. Keep registry authority in the caller and return immutable digest references plus provenance for downstream tests.

* fix(docker): use glibc in JVM development image

Use an Ubuntu-based Java 25 runtime so the JVM image can host glibc-linked integrations while preserving the existing entrypoint, tooling, and architecture behavior.

* ci: publish JVM images by default

* fix(ci): harden reusable image builds

* docs(ci): clarify image registry input

* fix(docker): locate the installed AWS CLI

* fix(ci): tag images by build time and revision
2026-08-05 17:06:07 -05:00

40 lines
1.7 KiB
Docker

ARG VERSION=latest
# This must be the UBI-based image produced by Dockerfile.native-package.
# Release and nightly tags use VERSION; reusable builds override BASE_IMAGE
# with the digest-qualified native image they just published.
ARG BASE_IMAGE=floci/floci:${VERSION}
FROM ${BASE_IMAGE}
LABEL org.opencontainers.image.title="Floci (compat)" \
org.opencontainers.image.description="Floci compatibility image with AWS CLI and boto3 pre-installed" \
org.opencontainers.image.url="https://floci.io" \
org.opencontainers.image.source="https://github.com/floci-io/floci" \
org.opencontainers.image.licenses="MIT" \
org.opencontainers.image.vendor="Floci"
ENV AWS_DEFAULT_REGION=us-east-1
ENV AWS_ACCESS_KEY_ID=test
ENV AWS_SECRET_ACCESS_KEY=test
ENV AWS_ENDPOINT_URL="http://localhost:4566"
ENV AWS_CONFIG_FILE=/etc/floci/aws/config
USER root
RUN microdnf install -y --nodocs python3 python3-pip \
&& pip3 install --no-cache-dir awscli boto3 \
&& microdnf clean all \
&& rm -rf /root/.cache/pip
COPY bin/awslocal /usr/local/bin/awslocal
RUN chmod +x /usr/local/bin/awslocal
# Pre-create the init-hook directories so archive-based copies (Testcontainers
# withCopyFileToContainer / `docker cp`) can drop hooks straight into them.
# Docker's archive extract unpacks into an existing dir and never mkdir -p's the
# parents, so without these the copy fails. Mirrors LocalStack, which ships
# /etc/localstack/init. Owned by the runtime user (uid 1001, group root).
RUN mkdir -p /etc/localstack/init/boot.d /etc/localstack/init/start.d /etc/localstack/init/ready.d \
/etc/floci/init/boot.d /etc/floci/init/start.d /etc/floci/init/ready.d \
&& chown -R 1001:root /etc/localstack /etc/floci
USER 1001