Fix environment variable exports in start-services
This commit is contained in:
parent
0be46d328a
commit
a7a0854a5b
1 changed files with 39 additions and 0 deletions
39
start-services.sh
Executable file
39
start-services.sh
Executable file
|
|
@ -0,0 +1,39 @@
|
|||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
set -a
|
||||
source .env
|
||||
set +a
|
||||
|
||||
echo "Building workspace..."
|
||||
cargo build --workspace
|
||||
|
||||
echo "Stopping any previously running services..."
|
||||
pkill -f "target/debug/gateway" || true
|
||||
pkill -f "target/debug/users" || true
|
||||
pkill -f "target/debug/companies" || true
|
||||
pkill -f "target/debug/job_seekers" || true
|
||||
pkill -f "target/debug/customers" || true
|
||||
pkill -f "target/debug/photographers" || true
|
||||
pkill -f "target/debug/makeup_artists" || true
|
||||
pkill -f "target/debug/tutors" || true
|
||||
pkill -f "target/debug/developers" || true
|
||||
pkill -f "target/debug/video_editors" || true
|
||||
pkill -f "target/debug/graphic_designers" || true
|
||||
pkill -f "target/debug/social_media_managers" || true
|
||||
pkill -f "target/debug/fitness_trainers" || true
|
||||
pkill -f "target/debug/catering_services" || true
|
||||
pkill -f "target/debug/payments" || true
|
||||
|
||||
apps=(
|
||||
"gateway" "users" "companies" "job_seekers" "customers"
|
||||
"photographers" "makeup_artists" "tutors" "developers" "video_editors"
|
||||
"graphic_designers" "social_media_managers" "fitness_trainers" "catering_services" "payments"
|
||||
)
|
||||
|
||||
for app in "${apps[@]}"; do
|
||||
echo "Starting $app..."
|
||||
./target/debug/$app > "$app.log" 2>&1 &
|
||||
done
|
||||
|
||||
echo "All services booted up!"
|
||||
Loading…
Add table
Reference in a new issue