26 lines
642 B
Bash
Executable File
26 lines
642 B
Bash
Executable File
#!/bin/bash
|
|
set -e
|
|
|
|
echo "Installing system dependencies..."
|
|
sudo apt-get update -qq
|
|
sudo apt-get install -y \
|
|
libcap-dev \
|
|
python3-prctl \
|
|
python3-picamera2 \
|
|
python3-pil \
|
|
ffmpeg
|
|
|
|
echo "Configuring Poetry to use system site-packages..."
|
|
poetry config virtualenvs.options.system-site-packages true
|
|
|
|
echo "Removing existing venv to ensure clean state..."
|
|
poetry env remove python3 2>/dev/null || true
|
|
|
|
echo "Installing Python dependencies..."
|
|
poetry install --without pi
|
|
|
|
echo "Verifying picamera2 is accessible..."
|
|
poetry run python -c "import picamera2; print(f'picamera2 found at: {picamera2.__file__}')"
|
|
|
|
echo "Done!"
|