-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathverify_setup.sh
More file actions
executable file
·82 lines (72 loc) · 1.97 KB
/
verify_setup.sh
File metadata and controls
executable file
·82 lines (72 loc) · 1.97 KB
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
#!/bin/bash
echo "🔍 Verifying Forge Master Infrastructure Setup..."
echo ""
# Check gcloud installation
echo "1. Checking gcloud CLI..."
if command -v gcloud &> /dev/null; then
echo " ✅ gcloud CLI installed"
gcloud version | head -n 1
else
echo " ❌ gcloud CLI not found"
fi
echo ""
# Check project
echo "2. Checking active project..."
PROJECT=$(gcloud config get-value project)
if [ -n "$PROJECT" ]; then
echo " ✅ Active project: $PROJECT"
else
echo " ❌ No active project set"
fi
echo ""
# Check enabled APIs
echo "3. Checking enabled APIs..."
REQUIRED_APIS=(
"run.googleapis.com"
"cloudbuild.googleapis.com"
"storage.googleapis.com"
"firestore.googleapis.com"
"aiplatform.googleapis.com"
)
for api in "${REQUIRED_APIS[@]}"; do
if gcloud services list --enabled --filter="name:$api" --format="value(name)" | grep -q "$api"; then
echo " ✅ $api"
else
echo " ❌ $api (not enabled)"
fi
done
echo ""
# Check Cloud Storage bucket
echo "4. Checking Cloud Storage bucket..."
if gcloud storage buckets list --format="value(name)" | grep -q "forge-master"; then
echo " ✅ Bucket exists"
gcloud storage buckets list --filter="name:forge-master*"
else
echo " ❌ Bucket not found"
fi
echo ""
# Check Firestore
echo "5. Checking Firestore..."
if gcloud firestore databases list &> /dev/null; then
echo " ✅ Firestore database exists"
else
echo " ❌ Firestore not initialized"
fi
echo ""
# Check service account
echo "6. Checking service account..."
if gcloud iam service-accounts list --filter="email:forge-master-sa@" --format="value(email)" | grep -q "forge-master"; then
echo " ✅ Service account exists"
else
echo " ❌ Service account not found"
fi
echo ""
# Check environment file
echo "7. Checking environment file..."
if [ -f ".env" ]; then
echo " ✅ .env file exists"
else
echo " ❌ .env file not found"
fi
echo ""
echo "✅ Infrastructure verification complete!"