Skip to content

Commit

Permalink
archlinux: create and use a virtual environment for Python packages
Browse files Browse the repository at this point in the history
  • Loading branch information
TSC21 committed May 16, 2024
1 parent e1931eb commit e0e94c2
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 6 deletions.
15 changes: 11 additions & 4 deletions docker/Dockerfile_base-archlinux
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,17 @@ RUN pacman -Sy --noconfirm \
wget \
zip

# Python 3 dependencies installed by pip
RUN pip3 install argparse argcomplete coverage cerberus empy==3.3.4 jinja2 kconfiglib \
matplotlib==3.0.* numpy packaging pkgconfig pyros-genmsg pyulog \
pyyaml requests serial six toml psutil pyulog wheel jsonschema
# Create a virtual environment for Python packages
RUN python3 -m venv /opt/venv
ENV PATH="/opt/venv/bin:$PATH"

# Install wheel and setuptools in the virtual environment
RUN pip3 install wheel setuptools

# Python 3 dependencies installed by pip inside the virtual environment
RUN pip3 install argparse argcomplete coverage cerberus empy==3.3.4 jinja2 \
kconfiglib matplotlib==3.0.* numpy packaging pkgconfig pyros-genmsg \
pyulog pyyaml requests serial six toml psutil pyulog wheel jsonschema

# Install genromfs
RUN wget https://sourceforge.net/projects/romfs/files/genromfs/0.5.2/genromfs-0.5.2.tar.gz \
Expand Down
4 changes: 2 additions & 2 deletions docker/Dockerfile_base-jammy
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ RUN cd /usr/src/gtest \
RUN python3 -m pip install --upgrade pip wheel setuptools

# Python 3 dependencies installed by pip
RUN python3 -m pip install argparse argcomplete coverage cerberus empy==3.3.4 jinja2 kconfiglib \
matplotlib>=3.0.* numpy nunavut>=1.1.0 packaging pkgconfig pyros-genmsg pyulog \
RUN python3 -m pip install argparse argcomplete coverage cerberus empy==3.3.4 jinja2 \
kconfiglib matplotlib numpy nunavut>=1.1.0 packaging pkgconfig pyros-genmsg pyulog \
pyyaml requests serial six toml psutil pyulog wheel jsonschema pynacl lxml

#RUN python3 -m pip install argcomplete argparse>=1.2 cerberus coverage empy>=3.3 future \
Expand Down

0 comments on commit e0e94c2

Please sign in to comment.