Gallery Data Migration Tool

⚠️ IMPORTANT: Set Firebase Rules First!

Before running migration, you MUST update your Firebase Realtime Database rules or you'll get permission errors.

Quick Setup:

  1. Go to Firebase Console
  2. Select project: ntbtstws
  3. Click Realtime DatabaseRules tab
  4. Replace all rules with:
    {
      "rules": {
        "gallery": {
          ".read": true,
          ".write": true
        }
      }
    }
  5. Click Publish
  6. Come back here and click "Start Migration" below

⚠️ These are temporary permissive rules for migration only! See FIREBASE-SETUP.md for production rules.

What This Tool Does:

  1. Reads all category JSON files from /images/gallery/
  2. Uploads each image to /gallery/approved/{category} in Firebase
  3. Preserves all metadata (artist, source, date, path)
  4. Shows progress as it runs

Note: This is a one-time operation. Run it once after setting up Firebase rules.