Skip to content

Commit

Permalink
Resolved merge conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
patrickbdevaney committed Jan 3, 2025
1 parent 69d95d2 commit 6c83be7
Showing 1 changed file with 0 additions and 42 deletions.
42 changes: 0 additions & 42 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,44 +1,3 @@
<<<<<<< HEAD
# Use an official Python runtime as a parent image
FROM python:3.11-slim-bullseye

# Set environment variables for Python behavior
ENV PYTHONDONTWRITEBYTECODE=1 \
PYTHONUNBUFFERED=1 \
PIP_NO_CACHE_DIR=1 \
PIP_DISABLE_PIP_VERSION_CHECK=1 \
PIP_DEFAULT_TIMEOUT=100

# Set the working directory to the root of the project (relative to pyproject.toml)
WORKDIR /usr/src/app

# Copy the entire project into the container
COPY . .

# Install Poetry
RUN pip install poetry

# Configure Poetry to avoid virtual environments and install dependencies
RUN poetry config virtualenvs.create false && poetry install --no-interaction --no-ansi

# Install additional dependencies outside Poetry (e.g., swarms, pytest)
RUN pip install swarms pytest

# Ensure pytest is installed and available
RUN pytest --version

# Ensure the logs directory has correct permissions (in case of permission issues with mounted volumes)
RUN mkdir -p /usr/src/app/logs && chmod -R 777 /usr/src/app/logs

# Ensure that the PATH includes the directory where pytest is installed
ENV PATH="/usr/local/bin:$PATH"

# Set the working directory to the tests directory inside the container
WORKDIR /usr/src/app/tests

# Default command to run tests located in the /tests directory
CMD pytest /usr/src/app/tests --continue-on-collection-errors --tb=short --disable-warnings | tee /usr/src/app/logs/test_logs.txt
=======
# Use Python 3.11 slim-bullseye for smaller base image
FROM python:3.11-slim-bullseye AS builder

Expand Down Expand Up @@ -94,4 +53,3 @@ USER $USER
# Health check
HEALTHCHECK --interval=30s --timeout=30s --start-period=5s --retries=3 \
CMD python -c "import swarms; print('Health check passed')" || exit 1
>>>>>>> upstream/master

0 comments on commit 6c83be7

Please sign in to comment.