mirror of
https://github.com/dograh-hq/dograh.git
synced 2026-06-22 08:38:13 +02:00
2.2 KiB
2.2 KiB
Docker Build Instructions
Pipecat Submodule Integration
The Dograh project uses pipecat as a git submodule. The Docker build process automatically synchronizes the pipecat version between the submodule and the Docker image.
How It Works
- Automatic Version Sync: The Dockerfile accepts
PIPECAT_COMMITas a build argument - CI/CD: GitHub Actions automatically extract the submodule commit and pass it during build
- Local Development: Use the provided scripts or set the environment variable
Building Locally
Option 1: Using the Helper Script (Recommended)
# From the dograh directory
./scripts/docker-build-local.sh
This script automatically:
- Extracts the pipecat commit from the submodule
- Sets the PIPECAT_COMMIT environment variable
- Runs docker-compose build with the correct version
Option 2: Manual Build with docker-compose
# From the dograh directory
export PIPECAT_COMMIT=$(./scripts/get_pipecat_commit.sh)
docker-compose build
Option 3: Direct Docker Build
# From the dograh directory
PIPECAT_COMMIT=$(./scripts/get_pipecat_commit.sh)
docker build --build-arg PIPECAT_COMMIT=$PIPECAT_COMMIT -f api/Dockerfile ./api
Updating Pipecat
When you update the pipecat submodule:
-
Update the submodule to the desired commit:
cd pipecat git checkout <desired-commit> cd .. git add pipecat git commit -m "Update pipecat submodule" -
No Dockerfile changes needed! The build process automatically uses the new commit.
-
Push your changes - the CI/CD pipeline will automatically build with the correct version.
Troubleshooting
If you encounter build errors related to PIPECAT_COMMIT:
-
Ensure the pipecat submodule is initialized:
git submodule update --init --recursive -
Verify the submodule has a valid commit:
./scripts/get_pipecat_commit.sh -
For local builds, ensure you're using one of the methods above that sets PIPECAT_COMMIT.
Benefits
- ✅ No manual Dockerfile updates when pipecat is updated
- ✅ Guaranteed synchronization between submodule and Docker image
- ✅ Eliminates version mismatch errors
- ✅ Simpler workflow for developers