extract startup logic into server/startup.sh for easy customization
Replaces the inline bash -c "..." command in docker-compose with a dedicated startup.sh script that installs system packages, pip deps, and starts the server. Add custom setup steps (apt, pip, curl, etc.) in the marked section.
This commit is contained in:
+1
-6
@@ -4,12 +4,7 @@ services:
|
||||
container_name: mcp-bash
|
||||
restart: unless-stopped
|
||||
working_dir: /workspace
|
||||
command: |
|
||||
bash -c "
|
||||
apt-get update -qq &&
|
||||
apt-get install -y --no-install-recommends curl wget git vim nano htop procps jq less unzip &&
|
||||
pip install -q -r /app/requirements.txt &&
|
||||
cd /app && python -u main.py"
|
||||
command: bash /app/startup.sh
|
||||
ports:
|
||||
- "8000:8000"
|
||||
volumes:
|
||||
|
||||
Reference in New Issue
Block a user