Skip to content

An open-source, city/state-deployable web app for crowdsourced reporting of immigration enforcement activity. Think WAZE for ICE sightings. Optimized for speed, anonymity, and resilience.

Notifications You must be signed in to change notification settings

rocksaltdev/rocksalt

Repository files navigation

Rocksalt

An open-source, city/state-deployable web app for crowdsourced reporting of immigration enforcement activity. Think WAZE for ICE sightings. Optimized for speed, anonymity, and resilience.

Features

  • 🗺️ Real-time map of reported sightings
  • 📱 Mobile-first, dark mode interface
  • 🌐 Bilingual (English/Spanish)
  • 🔒 Privacy-focused (no tracking, EXIF stripping)
  • ⚡ Fast and lightweight
  • 🚀 Easy deployment per city

Tech Stack

  • Frontend: React + Vite + TypeScript
  • Styling: Tailwind CSS + shadcn/ui
  • Maps: Leaflet + OpenStreetMap
  • Backend: Supabase (PostgreSQL + PostGIS + Realtime)
  • i18n: react-i18next

Setup

Prerequisites

  • Node.js 18+
  • npm or yarn
  • Supabase account

Installation

  1. Clone the repository:
git clone <repo-url>
cd rocksalt
  1. Install dependencies:
npm install
  1. Copy environment variables:
cp .env.example .env
  1. Configure your .env file with your Supabase credentials and city settings.

  2. Set up Supabase:

    • Create a new Supabase project
    • Run the migrations in supabase/migrations/ in order:
      • 001_enable_postgis.sql
      • 002_create_tables.sql
      • 003_create_functions.sql
      • 004_create_policies.sql
      • 006_create_storage_policies.sql
    • Create a storage bucket named sighting-photos in Supabase Dashboard:
      • Go to Storage → Create bucket
      • Name: sighting-photos
      • Make it Public (toggle "Public bucket")
      • Then run 006_create_storage_policies.sql to set up permissions
    • (Optional) Set up pg_cron for 005_schedule_cron.sql
  3. Start the development server:

npm run dev

Deployment

Vercel

  1. Push your code to GitHub
  2. Import project in Vercel
  3. Add environment variables
  4. Deploy

Environment Variables

See .env.example for required variables.

VITE_SUPABASE_URL=https://xxxxx.supabase.co
VITE_SUPABASE_ANON_KEY=xxxxx

# Maps (Leaflet uses OpenStreetMap - no API key needed)
# VITE_MAPBOX_TOKEN=xxxxx

# City Configuration (Oklahoma State)
VITE_CITY_NAME="Oklahoma"
VITE_CITY_SLUG="ok"
VITE_BOUNDS_SW="33.6,-103.0"
VITE_BOUNDS_NE="37.0,-94.4"
VITE_DEFAULT_CENTER="35.4676,-97.5164"
VITE_DEFAULT_ZOOM=8

Project Structure

rocksalt/
├── src/
│   ├── components/      # React components
│   ├── hooks/          # Custom React hooks
│   ├── lib/            # Utility functions
│   ├── locales/        # i18n translations
│   ├── config/         # Location configuration
│   └── types/          # TypeScript types
├── supabase/
│   └── migrations/     # Database migrations
└── public/             # Static assets

License

MIT or AGPL-3.0

Legal Disclaimer

Rocksalt is a community information-sharing tool. Reporting and viewing public activity is protected speech. This app does not provide legal advice. If you need legal help, contact an immigration attorney or one of the resources listed in the app.

About

An open-source, city/state-deployable web app for crowdsourced reporting of immigration enforcement activity. Think WAZE for ICE sightings. Optimized for speed, anonymity, and resilience.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published