Backend for uploading, downloading and deleting files on Google Cloud.
API_URL="http://localhost:8080"
SERVICE_ACCOUNT_CREDENTIALS_PATH="./path_to_my_credential/credentials.json"
# Firebase environment variables
# https://firebase.google.com/docs/app-distribution/authenticate-service-account?platform=ios
API_KEY="my_api_key"
AUTH_DOMAIN="my_domain"
DATABASE_URL="my_database_url"
PROJECT_ID="firebase_project_id"
STORAGE_BUCKET="my-bucket.com"
MESSAGING_SENDER_ID="0000000"
APP_ID="id:00dsfdsljkjadslfkj"
Bun (JavaScript runtime and toolkit): installation link
To install project dependencies:
bun install
Apply prisma migrations:
# https://www.prisma.io/docs/orm/prisma-client/deployment/deploy-database-changes-with-prisma-migrate
npx prisma migrate deploy
Generate Prisma Client
# https://www.prisma.io/docs/orm/prisma-client/deployment/deploy-database-changes-with-prisma-migrate
npx prisma generate
To Run
bun run
- Multer NPM package
- Firebase - Authenticate with a service account
- Firebase Admin SDK
- Google cloud - Streaming-downloads
- Google cloud - Upload objects from memory
- Google cloud - Create a GET-signed URL