feat: optimize deployment and add debugging

This commit is contained in:
Jon
2025-07-30 22:06:52 -04:00
parent 2d98dfc814
commit dbe4b12f13
3 changed files with 22 additions and 13 deletions

View File

@@ -8,8 +8,6 @@ yarn-debug.log*
yarn-error.log*
# Build outputs
dist/
build/
.next/
out/
@@ -26,6 +24,9 @@ logs/
firebase-debug.log
firebase-debug.*.log
# Source files
src/
# Test files
coverage/
.nyc_output
@@ -38,11 +39,6 @@ tmp/
# Documentation and markdown files
*.md
AGENTIC_RAG_DATABASE_INTEGRATION.md
DATABASE.md
HYBRID_IMPLEMENTATION_SUMMARY.md
RAG_PROCESSING_README.md
go-forward-fixes-summary.md
# Scripts and setup files
*.sh

View File

@@ -1,10 +1,22 @@
#!/bin/bash
set -e
echo "Building TypeScript..."
npm run build
echo "Starting deployment script at $(date)"
echo "Deploying function to Firebase..."
echo "Listing current directory contents:"
ls -la
echo "Checking size of node_modules before build:"
du -sh node_modules
echo "Building TypeScript at $(date)..."
npm run build
echo "Finished building TypeScript at $(date)"
echo "Checking size of dist directory:"
du -sh dist
echo "Deploying function to Firebase at $(date)..."
gcloud functions deploy api \
--gen2 \
--runtime nodejs20 \
@@ -12,4 +24,6 @@ gcloud functions deploy api \
--source . \
--entry-point api \
--trigger-http \
--allow-unauthenticated
--allow-unauthenticated
echo "Finished deployment at $(date)"

3
package-lock.json generated
View File

@@ -9,8 +9,7 @@
"version": "1.0.0",
"license": "MIT",
"dependencies": {
"axios": "^1.11.0",
"form-data": "^4.0.4"
"axios": "^1.11.0"
},
"devDependencies": {
"concurrently": "^8.2.2"