Add bsdmainutils to requirements (#1667)

- `column` util was missing from the Docker image, added it and
organised the requirements file so it's more human friendly
- rearranged the USER argument in the Dockerfile to avoid the scenario
where you didnt specify the user and so lose the layers where apt
installed all the packages
- add the python deps at the end to ensure docker can reuse cached
layers if a python dep changes.
- update maspsx (I wanted to test latest maspsx against sotn, so this is
what led to the other changes!)
This commit is contained in:
Mark Street 2024-09-25 00:54:32 +01:00 committed by GitHub
parent 05a3ce0211
commit f573a99ec1
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 25 additions and 12 deletions

View File

@ -6,22 +6,21 @@
# make extract -j && make build -j
FROM ubuntu:22.04
ADD /tools/requirements-debian.txt /tools/requirements-debian.txt
RUN apt-get update && apt-get install -y $(cat /tools/requirements-debian.txt)
WORKDIR /sotn
ARG USER
RUN adduser ${USER}
RUN apt-get update
ADD tools tools
RUN apt-get install -y $(cat tools/requirements-debian.txt)
RUN mkdir /sotn
WORKDIR /sotn
ENV VENV_PATH=/tools/.venv
RUN mkdir $VENV_PATH
RUN chown ${USER} /sotn $VENV_PATH
RUN mkdir -p ${VENV_PATH}
RUN chown ${USER} /sotn ${VENV_PATH}
USER ${USER}
# this is similar to `make python-dependencies`, however,
# the Makefile is not available until a container has
# been created.
RUN cd /sotn && \
python3 -m venv $VENV_PATH && \
. $VENV_PATH/bin/activate && \
ADD tools/requirements-python.txt /tools/requirements-python.txt
RUN python3 -m venv ${VENV_PATH} && \
. ${VENV_PATH}/bin/activate && \
pip install -r /tools/requirements-python.txt
RUN git config --global --add safe.directory /sotn

@ -1 +1 @@
Subproject commit 7b7652969f43a461d385e78392cc7cd40e29b0a2
Subproject commit d2d24c407cc2f0aff0657afe3e5f0bf2e004bdba

View File

@ -1 +1,15 @@
git wget curl make gcc-mipsel-linux-gnu binutils-mipsel-linux-gnu clang-format python3-pip python3-venv p7zip-full bchunk unzip binutils-sh-elf cargo
bchunk
binutils-mipsel-linux-gnu
binutils-sh-elf
bsdmainutils
cargo
clang-format
curl
gcc-mipsel-linux-gnu
git
make
p7zip-full
python3-pip
python3-venv
unzip
wget