Add unit tests for connectors configuration, logger, workflows, and predictions batch - Implement tests for MLflow, OPC, and Postgres configuration builders to validate environment variable handling and default values. - Create tests for the logger to ensure default settings and handler configurations are correct. - Add comprehensive tests for the FormatAndExportPrediction and PredictionProcess workflows, covering various scenarios including path flags and activity execution. - Introduce tests for the PredictionsBatch workflow to verify the execution of local activities and child workflows. - Include a values.yaml file for Kubernetes deployment configuration, specifying image details, service account settings, environment variables, and resource limits.
31 lines
884 B
Docker
31 lines
884 B
Docker
# syntax=docker/dockerfile:1.4
|
|
|
|
FROM python:3.11-slim
|
|
|
|
# Enable use of SSH agent/socket
|
|
# This line enables SSH during build
|
|
# (don't forget the syntax header above)
|
|
RUN apt-get update && apt-get install -y git openssh-client && rm -rf /var/lib/apt/lists/*
|
|
|
|
# Use build-time SSH mount for Git clone
|
|
# The SSH key will NOT remain in the image
|
|
# IMPORTANT: this block requires BuildKit
|
|
# and the --ssh flag during docker build
|
|
|
|
# SSH config to skip host key check (safe in CI/local dev)
|
|
RUN mkdir -p /root/.ssh && echo "StrictHostKeyChecking no" > /root/.ssh/config
|
|
|
|
WORKDIR /app
|
|
|
|
# Clone using SSH
|
|
ARG GIT_REPO
|
|
ARG GIT_BRANCH=main
|
|
|
|
# Mount SSH key just for this RUN
|
|
RUN --mount=type=ssh git clone --branch ${GIT_BRANCH} ${GIT_REPO} .
|
|
|
|
# Install requirements if exists
|
|
RUN if [ -f requirements.txt ]; then pip install --no-cache-dir -r requirements.txt; fi
|
|
|
|
CMD ["python", "server.py"]
|