#!/bin/bash
# CAESES Data Center startup script

SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
EXECUTABLE="$SCRIPT_DIR/caeses-datacenter"

echo "Starting CAESES Data Center..."
echo "Configuration files are available in the 'configs' directory"
echo "Copy the appropriate config template to .env and customize as needed"
echo

# Check if executable exists and is executable
if [ ! -x "$EXECUTABLE" ]; then
    echo "ERROR: Executable not found or not executable: $EXECUTABLE"
    exit 1
fi

# Run the application
exec "$EXECUTABLE" "$@"
