mirror of
https://github.com/pacnpal/simpleguardhome.git
synced 2025-12-20 04:21:13 -05:00
feat(docker): simplify PYTHONPATH configuration and update entrypoint script to change directory before starting the application
This commit is contained in:
@@ -20,7 +20,7 @@ RUN pip install --no-cache-dir -r requirements.txt
|
|||||||
COPY . .
|
COPY . .
|
||||||
|
|
||||||
# Set Python path to include src directory
|
# Set Python path to include src directory
|
||||||
ENV PYTHONPATH="/app/src:${PYTHONPATH}"
|
ENV PYTHONPATH=/app/src
|
||||||
|
|
||||||
# Install the package in editable mode
|
# Install the package in editable mode
|
||||||
RUN pip install -e .
|
RUN pip install -e .
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ trap handle_term SIGTERM SIGINT
|
|||||||
|
|
||||||
# Start the application
|
# Start the application
|
||||||
echo "Starting SimpleGuardHome server..."
|
echo "Starting SimpleGuardHome server..."
|
||||||
PYTHONPATH=/app/src python -m simpleguardhome.main &
|
cd /app && PYTHONPATH=/app/src python3 -m simpleguardhome.main &
|
||||||
|
|
||||||
# Store child PID
|
# Store child PID
|
||||||
child=$!
|
child=$!
|
||||||
|
|||||||
Reference in New Issue
Block a user