#!/bin/bash
cd "$(dirname "$0")"

# Настройки подключения к БД (можно изменить через переменные окружения)
export DB_HOST=${DB_HOST:-localhost}
export DB_PORT=${DB_PORT:-5432}
export DB_USER=${DB_USER:-postgres}
export DB_PASSWORD=${DB_PASSWORD:-postgres}
export DB_NAME=${DB_NAME:-playlife}
export PORT=${PORT:-8080}

echo "Starting backend server..."
echo "DB_HOST: $DB_HOST"
echo "DB_PORT: $DB_PORT"
echo "DB_USER: $DB_USER"
echo "DB_NAME: $DB_NAME"
echo "PORT: $PORT"
echo ""

go run main.go
