fix(mitmproxy): Use Alpine package instead of pip install
mitmproxy_rs now requires Rust compilation which fails in chroot environment without /proc mounted. Switch to Alpine's pre-built mitmproxy package from the community repository. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
parent
58b4fbf10d
commit
87e6c53872
@ -301,26 +301,17 @@ lxc_create_alpine_rootfs() {
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
# Update and install dependencies
|
# Enable community repository for mitmproxy package
|
||||||
|
sed -i 's|#\(.*community\)|\1|' /etc/apk/repositories
|
||||||
|
|
||||||
|
# Update and install mitmproxy from Alpine packages (pre-built, no Rust needed)
|
||||||
apk update
|
apk update
|
||||||
apk add --no-cache \
|
apk add --no-cache \
|
||||||
python3 \
|
mitmproxy \
|
||||||
py3-pip \
|
py3-pip \
|
||||||
py3-wheel \
|
|
||||||
py3-cryptography \
|
|
||||||
py3-openssl \
|
|
||||||
py3-cffi \
|
|
||||||
py3-brotli \
|
|
||||||
py3-yaml \
|
|
||||||
py3-tornado \
|
|
||||||
py3-urwid \
|
|
||||||
libffi \
|
|
||||||
openssl \
|
openssl \
|
||||||
ca-certificates
|
ca-certificates
|
||||||
|
|
||||||
# Install mitmproxy via pip
|
|
||||||
pip3 install --break-system-packages mitmproxy
|
|
||||||
|
|
||||||
# Create directories
|
# Create directories
|
||||||
mkdir -p /data /var/log/mitmproxy /etc/mitmproxy/addons
|
mkdir -p /data /var/log/mitmproxy /etc/mitmproxy/addons
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user