-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Rafael te Boekhorst <[email protected]> Signed-off-by: Tobias Wolf <[email protected]> Signed-off-by: Jan-Marten Brüggemann <[email protected]> Co-authored-by: Tobias Wolf <[email protected]> Co-authored-by: Jan-Marten Brüggemann <[email protected]>
- Loading branch information
1 parent
861d23a
commit 5f34579
Showing
4 changed files
with
53 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
# Builder | ||
FROM python:3.11 as builder | ||
|
||
ARG ROOKIFY_VERSION=0.0.0.dev0 | ||
ENV ROOKIFY_VERSION=$ROOKIFY_VERSION | ||
|
||
WORKDIR /app/rookify | ||
|
||
RUN pip install build | ||
COPY . /app/rookify/ | ||
RUN python -m build /app/rookify/ | ||
|
||
|
||
# Base | ||
FROM ubuntu:24.04 as base | ||
|
||
# Update packages required for Rookify | ||
RUN apt-get update && apt-get install -qy python3-pip-whl python3-rados python3-venv && apt-get clean | ||
|
||
# Generate virtualenv including system packages with simlinks | ||
RUN /usr/bin/python3 -m venv --system-site-packages /app/rookify/.venv | ||
|
||
|
||
# Rookify | ||
FROM base AS rookify | ||
LABEL org.opencontainers.image.source="https://github.com/SovereignCloudStack/rookify" | ||
|
||
ARG ROOKIFY_VERSION=0.0.0.dev0 | ||
ENV ROOKIFY_VERSION=$ROOKIFY_VERSION | ||
|
||
WORKDIR /app/rookify | ||
|
||
COPY --from=builder /app/rookify/dist/Rookify-${ROOKIFY_VERSION}-py3-none-any.whl ./src/ | ||
RUN .venv/bin/pip3 install ./src/Rookify-${ROOKIFY_VERSION}-py3-none-any.whl | ||
|
||
# Set the ENTRYPOINT to activate the venv and then run the 'rookify' command | ||
ENTRYPOINT [".venv/bin/rookify"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters