2025-12-03 16:09:42 +01:00
|
|
|
FROM archlinux:latest
|
2025-07-11 07:19:44 +02:00
|
|
|
|
2025-12-03 16:09:42 +01:00
|
|
|
# Update system and install core tooling
|
|
|
|
|
RUN pacman -Syu --noconfirm \
|
|
|
|
|
&& pacman -S --noconfirm --needed \
|
|
|
|
|
git \
|
|
|
|
|
make \
|
|
|
|
|
sudo \
|
|
|
|
|
python \
|
|
|
|
|
python-pip \
|
|
|
|
|
python-virtualenv \
|
|
|
|
|
python-setuptools \
|
|
|
|
|
python-wheel \
|
|
|
|
|
&& pacman -Scc --noconfirm
|
2025-07-11 07:19:44 +02:00
|
|
|
|
2025-12-03 16:09:42 +01:00
|
|
|
# Ensure local bin is in PATH (for pkgmgr links)
|
2025-07-11 07:19:44 +02:00
|
|
|
ENV PATH="/root/.local/bin:$PATH"
|
|
|
|
|
|
2025-12-03 16:09:42 +01:00
|
|
|
# Create virtual environment
|
2025-07-11 07:19:44 +02:00
|
|
|
ENV VIRTUAL_ENV=/root/.venvs/pkgmgr
|
2025-12-03 16:09:42 +01:00
|
|
|
RUN python -m venv $VIRTUAL_ENV
|
2025-07-11 07:19:44 +02:00
|
|
|
ENV PATH="$VIRTUAL_ENV/bin:$PATH"
|
|
|
|
|
|
2025-12-03 16:09:42 +01:00
|
|
|
# Working directory for the package-manager project
|
2025-07-11 07:19:44 +02:00
|
|
|
WORKDIR /root/Repositories/github.com/kevinveenbirkenbach/package-manager
|
2025-12-03 16:09:42 +01:00
|
|
|
|
|
|
|
|
# Copy local package-manager source into container
|
2025-07-11 07:19:44 +02:00
|
|
|
COPY . .
|
|
|
|
|
|
2025-12-03 16:09:42 +01:00
|
|
|
# Install Python dependencies and register pkgmgr inside the venv
|
2025-07-11 07:19:44 +02:00
|
|
|
RUN pip install --upgrade pip \
|
|
|
|
|
&& pip install PyYAML \
|
|
|
|
|
&& chmod +x main.py \
|
2025-12-03 16:09:42 +01:00
|
|
|
&& python main.py install package-manager --quiet --clone-mode shallow --no-verification
|
|
|
|
|
|
|
|
|
|
# Copy again to allow rebuild-based code changes
|
|
|
|
|
COPY . .
|
2025-07-11 07:19:44 +02:00
|
|
|
|
|
|
|
|
ENTRYPOINT ["pkgmgr"]
|
|
|
|
|
CMD ["--help"]
|