Files
Michael Ikehi f70363e4ca Complete fraud detection system implementation
- Implemented EDA, feature engineering, and model training pipeline
- Built ML model with optimized hyperparameters (94% F1-score)
- Developed REST API with Flask for real-time fraud prediction
- Created responsive web UI for transaction validation
- Added Docker containerization for easy deployment
- Included comprehensive documentation and usage examples
2025-04-23 13:11:55 +01:00

35 lines
923 B
Bash
Executable File

#!/bin/bash
# Script to deploy the Fraud Detection System to a cloud environment
# Set variables
PROJECT_NAME="fraud-detection-system"
REGION="us-central1"
IMAGE_NAME="fraud-detection"
IMAGE_TAG="latest"
# Build the Docker image
echo "Building Docker image..."
docker build -t ${IMAGE_NAME}:${IMAGE_TAG} ..
# Tag the image for Google Container Registry (example)
echo "Tagging image for GCR..."
docker tag ${IMAGE_NAME}:${IMAGE_TAG} gcr.io/${PROJECT_NAME}/${IMAGE_NAME}:${IMAGE_TAG}
# Push the image to the registry
echo "Pushing image to GCR..."
docker push gcr.io/${PROJECT_NAME}/${IMAGE_NAME}:${IMAGE_TAG}
# Deploy to Cloud Run (example)
echo "Deploying to Cloud Run..."
gcloud run deploy ${IMAGE_NAME} \
--image gcr.io/${PROJECT_NAME}/${IMAGE_NAME}:${IMAGE_TAG} \
--platform managed \
--region ${REGION} \
--allow-unauthenticated \
--memory 2Gi \
--cpu 2 \
--port 8000
echo "Deployment completed!"