Skip to content

Create your map of brunch (or other) spots, by creating pins with names and optionally photos.

Notifications You must be signed in to change notification settings

bilalakil/brunch-map

Repository files navigation

Brunch Map

The following Google APIs are utilised by this project and need to be enabled for it to work (not including the APIs that the Firebase CLI will handle automatically):

  • Maps JavaScript API
  • Maps Geocoding API
  • Manually enable Firebase Storage
  • Manually enable login services

Root: Firebase Deployment

# Install dependencies
npm i

# Select project
npx firebase use staging

# Deploy everything (Frontend would need to be built first)
npx firebase deploy

/app: Frontend

  • $GOOGLE_MAPS_API_KEY

Requires the above environment variables to be set.

cd app

# Install dependencies
npm i

# Build app
npx webpack --env branch=staging

# Watch for changes
npx webpack --watch --env branch=staging

# Firebase actions back in root..
cd ..

# Run local server
npx firebase serve

# Deploy
npx firebase deploy --only hosting

/database.rules.json: Database Rules

# Deploy
npx firebase deploy --only database

/storage.rules: Storage Rules

# Deploy
npx firebase deploy --only storage

/functions: Cloud Functions

  • googlemaps.key

Requires the above config variables to be set, i.e. via npx firebase functions:config:set googlemaps.key=....

cd functions

# Install dependencies
npm i

# Firebase actions back in root..
cd ..

# Running functions locally has not been successfully tested yet ;(

# Deploy
npx firebase deploy --only functions

Continuous Integration via GitHub Actions

# View config
less .github/workflows/{main,staging}-build-deploy.yml

# Code, commit, push, debug, repeat
# main and staging branches supported

About

Create your map of brunch (or other) spots, by creating pins with names and optionally photos.

Topics

Resources

Stars

Watchers

Forks