Skip to main content

Installation Methods

Choose the installation method that best suits your needs:

Verify Installation

After installation, verify everything is working:
1

Check service health

curl http://localhost:18080/health
Expected response:
{
  "status": "healthy",
  "version": "1.0.1",
  "services": {
    "database": "connected",
    "redis": "connected"
  }
}
2

List available providers

curl http://localhost:18080/api/v1/pulse/providers
Should return a list of available health providers.
3

Check logs

View application logs to ensure no errors:
# Docker deployment
docker-compose logs -f backend

# Direct installation
# Logs will be in the terminal where you ran main.py

Post-Installation Setup

To enable health device integrations, you need OAuth credentials from each provider.See the Configuration guide for detailed instructions on obtaining and setting up OAuth credentials for:
  • Garmin Connect
  • Whoop
  • Custom providers
To enable AI chat features, add API keys to config.yaml:
OPENROUTER_API_KEY: 'your_openrouter_api_key'
GOOGLE_API_KEY (Optional): 'your_google_api_key'
OPENAI_API_KEY (Optional): 'your_openai_api_key'
For production, set secure encryption keys:
DATABASE_DECRYPTION_KEY: 'your_32_char_encryption_key'
JWT_KEY: 'your_secure_jwt_secret'
Use strong, randomly generated keys in production. Never commit these to version control.
Configure S3-compatible storage for data backups:
S3_KEY: 'your_access_key'
S3_TOKEN: 'your_secret_key'
S3_REGION: 'us-east-1'
S3_BUCKET: 'your-bucket-name'

Directory Structure

After installation, your directory structure will look like this:
mirobody-health/
├── connect/                    # Provider integrations
│   ├── __init__.py
│   └── theta/                 # Theta platform providers
│       ├── mirobody_garmin_connect/
│       └── mirobody_whoop/
├── docker/                     # Docker configuration
│   ├── docker-compose.yaml
│   ├── Dockerfile.backend
│   ├── Dockerfile.base
│   └── Dockerfile.postgres
├── shell/                      # Utility scripts
│   ├── chat_test_commands.sh
│   └── get_tools.sh
├── config.yaml                 # Main configuration
├── .env                       # Environment variables
├── main.py                    # Application entry point
├── requirements.txt           # Python dependencies
├── setup.py                   # Package setup
└── README.md                  # Documentation

Troubleshooting Installation

Problem: Docker commands fail with permission errors.Solution:
# Linux: Add user to docker group
sudo usermod -aG docker $USER

# Log out and back in
newgrp docker
Problem: Port 18080 is already in use.Solution: Change the port in config.yaml:
HTTP_PORT: 18081  # Use any available port
Problem: Cannot connect to PostgreSQL.Solutions:
  1. Verify PostgreSQL is running:
    docker-compose ps postgres
    
  2. Check connection settings in config.yaml:
    PG_HOST: db  # 'db' for Docker, 'localhost' for local install
    PG_PORT: 5432
    PG_USER: holistic_user
    PG_DBNAME: holistic_db
    
  3. Check database logs:
    docker-compose logs postgres
    
Problem: Python 3.12 not available.Solutions:
brew install [email protected]
Problem: ModuleNotFoundError when running the application.Solution:
# Ensure all dependencies are installed
pip install -r requirements.txt

# Install in development mode
pip install -e .

Uninstallation

Remove all containers, volumes, and images:
# Stop and remove containers
docker-compose down

# Remove volumes (WARNING: This deletes all data)
docker-compose down -v

# Remove images
docker-compose down --rmi all

Next Steps