arcade-mcp/docker/Dockerfile
Sam Partee e7ccbe0efa
Dockerfiles for Actor container (#18)
#### Summary
This PR introduces key updates to the Arcade AI codebase, focusing on
improving the CLI tool, refining the Docker build process, and enhancing
documentation within the Gmail toolkit.

#### Key Changes:
1. **Docker Build**:
- Added the `--no-cache` option to the `docker-build` target in the
Makefile to ensure fresh builds, preventing issues related to cached
layers.

2. **CLI Tool**:
- Introduced a new optional `prompt` parameter in the `chat` command,
allowing users to customize the system role's prompt. A default prompt
is now provided if none is specified.

3. **Gmail Toolkit**:
- Updated the `write_draft` function with improved docstrings for
clearer guidance and maintainability.

#### Impact:
- **Developer Workflow**: Improved Docker reliability and enhanced CLI
flexibility.
- **User Experience**: More customizable interactions in the CLI and
better documentation in the Gmail toolkit.

Please review and provide feedback.
2024-08-22 16:28:42 -07:00

53 lines
1.1 KiB
Docker

# Use a lightweight Python image
FROM python:3.10-slim
# Set environment variables
ENV POETRY_VERSION=1.8.3
ENV PORT=8001
ENV HOST=0.0.0.0
# Install system dependencies
RUN apt-get update && apt-get install -y \
apt-utils \
build-essential \
libssl-dev \
libffi-dev \
python3-dev \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/*
# Install Poetry
RUN python -m pip install "poetry==$POETRY_VERSION"
# Set the working directory
WORKDIR /app
# Copy the parent directory contents into the container
COPY . .
WORKDIR /app/arcade
# Build the project and install the wheel with extras
RUN python -m poetry build && \
pip install dist/arcade_ai-0.1.0-py3-none-any.whl[fastapi,dev]
WORKDIR /app
# Install toolkits from the toolkits directory
RUN set -e; \
for toolkit in /app/toolkits/*; do \
echo "Installing toolkit $(basename $toolkit) "; \
cd $toolkit; \
python -m poetry build; \
pip install dist/*.whl; \
done
# Expose the port
EXPOSE $PORT
WORKDIR /app/arcade
RUN pip install uvicorn
# Run the arcade dev command
CMD arcade dev --host $HOST --port $PORT