From d817b4326cd6e13860010ad62e4157bf2870154d Mon Sep 17 00:00:00 2001 From: "CanbiZ (MickLesk)" <47820557+MickLesk@users.noreply.github.com> Date: Wed, 25 Mar 2026 15:38:18 +0100 Subject: [PATCH] fix(erpnext): bootstrap pip in uv venv for ansible install bench setup production internally runs: sudo -m pip install ansible but uv tool environments don't include pip by default. Fix: run ensurepip + pip install ansible before bench setup production to satisfy the dependency. --- install/erpnext-install.sh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/install/erpnext-install.sh b/install/erpnext-install.sh index b01876c0..994a7f42 100644 --- a/install/erpnext-install.sh +++ b/install/erpnext-install.sh @@ -82,6 +82,9 @@ $STD systemctl enable --now redis-server msg_ok "Configured ERPNext" msg_info "Setting up Production" +BENCH_VENV="/home/frappe/.local/share/uv/tools/frappe-bench" +$STD "${BENCH_VENV}/bin/python" -m ensurepip +$STD "${BENCH_VENV}/bin/python" -m pip install ansible $STD bash -c 'export PATH="/home/frappe/.local/bin:$PATH"; cd /opt/frappe-bench && bench setup production frappe --yes' $STD systemctl enable --now supervisor msg_ok "Set up Production"