This commit is contained in:
2025-11-03 10:54:29 +11:00
parent fc07c9e134
commit 9ab5a08646
5 changed files with 356 additions and 31 deletions
+16 -16
View File
@@ -10,13 +10,13 @@ echo "================="
# Check if Docker is installed
if command -v docker &> /dev/null; then
echo "✅ Docker found"
echo "🐳 Building Docker image..."
docker-compose build
echo "🚀 Starting YouMusic..."
docker-compose up -d
echo ""
echo "✨ YouMusic is running!"
echo "📱 Frontend: http://localhost:8000"
@@ -24,22 +24,22 @@ if command -v docker &> /dev/null; then
echo ""
echo "To stop: docker-compose down"
echo "To view logs: docker-compose logs -f"
else
echo "⚠️ Docker not found. Installing manually..."
# Check Python
if ! command -v python3 &> /dev/null; then
echo "❌ Python 3 is required but not installed"
exit 1
fi
# Check Node.js
if ! command -v node &> /dev/null; then
echo "❌ Node.js is required but not installed"
exit 1
fi
# Check FFmpeg
if ! command -v ffmpeg &> /dev/null; then
echo "⚠️ FFmpeg not found. Please install it:"
@@ -47,39 +47,39 @@ else
echo " macOS: brew install ffmpeg"
exit 1
fi
echo "✅ All dependencies found"
# Backend setup
echo "🔧 Setting up backend..."
cd backend
# Check if uv is installed
if ! command -v uv &> /dev/null; then
echo "Installing uv..."
curl -LsSf https://astral.sh/uv/install.sh | sh
export PATH="$HOME/.cargo/bin:$PATH"
fi
if [ ! -d ".venv" ]; then
uv venv --python 3.13
fi
uv sync
# Create data directories
mkdir -p ../data/music ../data/uploads ../data/temp
# Frontend setup
echo "🎨 Setting up frontend..."
cd ../frontend
npm install
npm run build
# Copy frontend build to backend static
mkdir -p ../backend/static
cp -r dist/* ../backend/static/
echo ""
echo "✨ Setup complete!"
echo ""