This repository was archived by the owner on Feb 6, 2026. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
Deployment
Janardhan B edited this page May 5, 2025
·
1 revision
This guide explains how to deploy the LangGraph Deployment Kit to production environments.
There are several ways to deploy the kit:
- Directly on a server
- Using Docker
- Using a cloud platform (AWS, Azure, GCP)
- Python 3.11 or higher
- A server with appropriate networking
- API keys for your LLM providers
-
Clone the repository on your server:
git clone https://github.com/your-username/langgraph-deployment-kit.git cd langgraph-deployment-kit -
Create a virtual environment and install dependencies:
python -m venv venv source venv/bin/activate # On Windows: venv\Scripts\activate pip install -e .
-
Configure environment variables:
cp .env.example .env # Edit .env with production settings -
Start the service (with a process manager like supervisord):
python src/run_service.py
- Docker installed
- Docker Compose (optional, for more complex setups)
-
Create a Dockerfile in the root directory:
FROM python:3.12-slim WORKDIR /app COPY . . RUN pip install -e . EXPOSE 8080 CMD ["python", "src/run_service.py"]
-
Build and run the Docker container:
docker build -t langgraph-deployment-kit . docker run -p 8080:8080 --env-file .env langgraph-deployment-kit
- Install the AWS EB CLI
- Configure your application:
eb init
- Create an environment and deploy:
eb create
- Install the Google Cloud SDK
- Build and push your Docker image:
gcloud builds submit --tag gcr.io/your-project/langgraph-deployment-kit
- Deploy to Cloud Run:
gcloud run deploy --image gcr.io/your-project/langgraph-deployment-kit --platform managed
- Always set
AUTH_SECRETto a strong random string - Use HTTPS in production environments
- Consider using a reverse proxy like Nginx
- For high traffic, consider using a database like PostgreSQL instead of SQLite
- Set up proper monitoring and logging
- Implement rate limiting if needed
- Set up Langfuse for observability
- Consider adding Prometheus metrics
- Set up uptime monitoring
Key environment variables for production:
-
MODE: Set to "deployment" in production -
HOSTandPORT: Configure according to your environment -
AUTH_SECRET: A secure authentication key -
DATABASE_TYPE: "postgres" recommended for production -
POSTGRES_*: Configure your PostgreSQL connection
© 2024 LangGraph Deployment Kit by Janardhan B | MIT License | Last updated: May 6, 2025