fix fedora python deps bug

This commit is contained in:
Florian Pitance 2022-11-15 16:51:48 +01:00 committed by GitHub
parent f2eabc0df6
commit 93c74154ab
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 2 deletions

View File

@ -29,7 +29,9 @@ RUN dnf install -y python3-pip brotli brotli-devel gperftools-devel perl libxslt
chmod +x /tmp/bunkerweb/deps/install.sh && \
bash /tmp/bunkerweb/deps/install.sh && \
mkdir /usr/share/bunkerweb/deps/python && \
pip install --no-cache-dir --require-hashes --target /usr/share/bunkerweb/deps/python -r /tmp/bunkerweb/deps/requirements.txt
# Dirty fix to avoid errors with --target and packages same namespace
cp -r /usr/lib64/python3.10/* /usr/lib/python3.10/ && \
PYTHONPLATLIBDIR=lib pip3.10 install --no-cache-dir --require-hashes --target /usr/share/bunkerweb/deps/python -r /tmp/bunkerweb/deps/requirements.txt
# Copy files
# can't exclude deps from . so we are copying everything by hand
@ -78,4 +80,4 @@ COPY src/linux/bunkerweb-ui.service /usr/share/bunkerweb-ui.service
# Generate DEB at startup
VOLUME /data
WORKDIR /usr/share/
ENTRYPOINT ["/usr/share/fpm.sh", "deb"]
ENTRYPOINT ["/usr/share/fpm.sh", "deb"]