Skip to content

Commit 0663790

Browse files
committed
fix mongodb connection - alogin
1 parent b1ed30e commit 0663790

2 files changed

Lines changed: 3 additions & 15 deletions

File tree

backend/microservices/user-service/functions/src/logger/authLogger.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,7 @@ const connectMongoDB = async () => {
2525
}
2626
};
2727

28-
// Initialize connection
29-
// Make this export so we can properly test it
30-
export const initMongoDB = () => connectMongoDB();
28+
connectMongoDB();
3129

3230
// Auth Log Schema remains the same...
3331
const authLogSchema = new mongoose.Schema({

launch.sh

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22

3-
./env-fetch.sh
3+
#./env-fetch.sh
44
# Color codes for better visibility
55
RED='\033[0;31m'
66
GREEN='\033[0;32m'
@@ -23,17 +23,7 @@ check_directory() {
2323
# Function to install dependencies
2424
install_dependencies() {
2525
log "${YELLOW}Installing dependencies in $(pwd)...${NC}"
26-
if [ "$EUID" -ne 0 ]; then
27-
echo "Some installations may require elevated privileges..."
28-
if command -v sudo >/dev/null 2>&1; then
29-
sudo -S npm install
30-
else
31-
echo "sudo is not installed. Please run this script with root privileges or install sudo"
32-
exit 1
33-
fi
34-
else
35-
npm install
36-
fi
26+
npm install
3727
}
3828

3929
# Store the root directory

0 commit comments

Comments
 (0)