Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 10 additions & 9 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,20 +1,21 @@
FROM python:3.11-slim

# Sample dockerfile to generate image for testing container mgr
# Use a minimal base image and install dependencies needed for Python package builds.
ENV PIP_NO_CACHE_DIR=1

RUN apt-get -y update && apt-get -y upgrade

RUN pip install grpcio grpcio_tools
RUN apt-get update \
&& apt-get upgrade -y \
&& apt-get install -y --no-install-recommends ca-certificates \
&& rm -rf /var/lib/apt/lists/*

WORKDIR /home

COPY ./volpe_py ./volpe_py

COPY requirements.txt .
RUN python -m pip install --upgrade pip setuptools wheel \
&& python -m pip install --prefer-binary -r requirements.txt

RUN pip install -r requirements.txt

COPY ./volpe_py ./volpe_py
COPY . .

CMD [ "/usr/local/bin/python3", "./main.py" ]
CMD ["python", "./main.py"]

15 changes: 11 additions & 4 deletions build_image.sh
Original file line number Diff line number Diff line change
@@ -1,5 +1,12 @@
DOCKER_CMD="${DOCKER_CMD:-podman}"
#!/usr/bin/env bash
set -euo pipefail

rm volpe_img.tar
$DOCKER_CMD build -t volpe_grpc_test .
$DOCKER_CMD save -o volpe_img.tar volpe_grpc_test
DOCKER_CMD="${DOCKER_CMD:-$(command -v podman || command -v docker || true)}"
if [ -z "$DOCKER_CMD" ]; then
echo "Error: podman or docker command is required."
exit 1
fi

rm -f volpe_img.tar
"$DOCKER_CMD" build -t volpe_grpc_test .
"$DOCKER_CMD" save -o volpe_img.tar volpe_grpc_test
4 changes: 2 additions & 2 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
numpy
opfunu
grpcio-tools
protobuf
grpcio-tools>=1.78.1
protobuf>=6.31.0
setuptools<81
deap