Skip to content

Commit

Permalink
fix container
Browse files Browse the repository at this point in the history
  • Loading branch information
XdoctorwhoZ committed Nov 27, 2023
1 parent 0cb94ba commit e91e5e3
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
14 changes: 6 additions & 8 deletions platform/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ LABEL org.opencontainers.image.source https://github.com/Panduza/panduza-py
# Install Packages
RUN apt-get update && DEBIAN_FRONTEND=noninteractive TZ=Europe/Paris \
apt-get -y install \
python3 python3-pip \
python3.11 python3-pip \
git

# Append udev and libusb for device autodetection
Expand All @@ -15,25 +15,23 @@ RUN apt-get -y install libusb-1.0-0

# Pip installations
COPY requirements.txt /setup/requirements.txt
RUN pip3 install -r /setup/requirements.txt
RUN python3.11 -m pip install -r /setup/requirements.txt

# Create the mirror directory
RUN mkdir -p /etc/panduza

#
# Install platform inside
WORKDIR /setup
COPY . /setup/
RUN pip install .
# RUN cp -v ./deploy/pza-py-platform-run.py /usr/local/bin/pza-py-platform-run.py
RUN python3.11 -m pip install .

# Allow plugin insertion here
ENV PYTHONPATH="/etc/panduza/plugins/py"
# ENV PYTHONPATH="/etc/panduza/plugins/py"

#
WORKDIR /work

# Create the directory for platform plugins
# Then run the platform
CMD mkdir -p /etc/panduza/plugins/py; \
python3 /usr/local/lib/python3.10/dist-packages/panduza_platform/__main__.py

python3.11 /usr/local/lib/python3.11/dist-packages/panduza_platform/__main__.py
2 changes: 2 additions & 0 deletions platform/scripts/docker.bash.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@

docker run -it local/panduza-py-platform:latest bash

0 comments on commit e91e5e3

Please sign in to comment.