mirror of
https://github.com/rybbit-io/rybbit.git
synced 2025-05-10 11:55:37 +02:00
* Enhance setup and configuration for self-hosting - Updated `.env.example` to include new webserver configuration options. - Modified `docker-compose.yml` to support custom port bindings for backend and client services when not using the built-in webserver. - Enhanced `setup.sh` to handle `--no-webserver` flag, allowing users to run their own webserver and exposing necessary ports. - Expanded documentation in `self-hosting.mdx` to include instructions for using a custom webserver and managing services. * Refactor environment variable configuration and enhance setup script - Updated `.env.example` to use HOST_BACKEND_PORT and HOST_CLIENT_PORT for clearer port mapping. - Modified `docker-compose.yml` to reflect changes in environment variable names for backend and client services. - Enhanced `setup.sh` to support custom port options and improved error handling for missing `.env` file. - Updated documentation in `self-hosting.mdx` to include new setup script options and examples for custom port configurations. * docker publish
30 lines
No EOL
707 B
Bash
30 lines
No EOL
707 B
Bash
#!/bin/bash
|
|
|
|
# Exit immediately if a command exits with a non-zero status.
|
|
set -e
|
|
|
|
echo "Restarting services..."
|
|
|
|
# Stop all services
|
|
docker compose stop
|
|
|
|
# Check if .env file exists
|
|
if [ ! -f .env ]; then
|
|
echo "Error: .env file not found. Please run setup.sh first."
|
|
echo "Usage: ./setup.sh <domain_name>"
|
|
exit 1
|
|
fi
|
|
|
|
# Load environment variables
|
|
source .env
|
|
|
|
# Start the appropriate services
|
|
if [ "$USE_WEBSERVER" = "false" ]; then
|
|
# Start without the caddy service when using --no-webserver
|
|
docker compose start backend client clickhouse postgres
|
|
else
|
|
# Start all services including caddy
|
|
docker compose start
|
|
fi
|
|
|
|
echo "Services restarted. You can monitor logs with: docker compose logs -f" |