forked from ChangwenXu98/TransPolymer
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdeploy-heroku.sh
More file actions
executable file
·34 lines (27 loc) · 883 Bytes
/
deploy-heroku.sh
File metadata and controls
executable file
·34 lines (27 loc) · 883 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#!/bin/bash
# Heroku Deployment Script for TransPolymer
echo "🚀 Deploying TransPolymer to Heroku..."
# Check if Heroku CLI is installed
if ! command -v heroku &> /dev/null; then
echo "❌ Heroku CLI not found. Please install it first:"
echo " https://devcenter.heroku.com/articles/heroku-cli"
exit 1
fi
# Add all changes
echo "📦 Adding files to git..."
git add .
# Commit changes
echo "💾 Committing changes..."
git commit -m "Optimize for Heroku deployment with CPU-only PyTorch"
# Deploy to Heroku
echo "🌊 Deploying to Heroku..."
git push heroku main
echo "✅ Deployment complete!"
echo "🌐 Your app should now be running with optimized dependencies"
echo "📊 Estimated slug size: ~200-300MB (down from 3.1GB)"
# Optional: Open the app
read -p "Open your app in browser? (y/n): " -n 1 -r
echo
if [[ $REPLY =~ ^[Yy]$ ]]; then
heroku open
fi