Fixed dockerfile

This commit is contained in:
Alessandro Santini
2025-02-02 10:33:48 +01:00
parent 96ba1dfa1b
commit 47f5d4921b

View File

@@ -7,15 +7,14 @@ WORKDIR /app
RUN pip install poetry RUN pip install poetry
# Copy project files # Copy project files
COPY pyproject.toml poetry.lock ./ COPY pyproject.toml poetry.lock README.md ./
COPY main.py . COPY main.py .
COPY .env .
# Configure Poetry to not create a virtual environment # Configure Poetry to not create a virtual environment
RUN poetry config virtualenvs.create false RUN poetry config virtualenvs.create false
# Install dependencies # Install dependencies (only production)
RUN poetry install --no-dev --no-interaction --no-ansi RUN poetry install --only main --no-interaction --no-ansi --no-root
# Run the bot # Run the bot
CMD ["python", "main.py"] CMD ["python", "main.py"]