RRupert

Getting started

Run Rupert locally with Ruby, PostgreSQL, and the Shopify tooling it needs.

Requirements

Set up

# 1. Install gems (from web/)
bundle install

# 2. Copy the env template and fill in credentials
cp .env.example .env

# 3. Create the postgres role + db (or set POSTGRES_* env vars)
createuser -s rupert
createdb -O rupert rupert_development

# 4. Prepare the database
bin/rails db:create db:migrate

# 5. Build the Tailwind CSS
bin/rails tailwindcss:build

# 6. Run the server
bin/rails server          # http://localhost:3000

Environment variables

The .env at the repo root is loaded at boot (Dotenv) and holds the sync-engine credentials:

When developing through the Shopify CLI, the OAuth pair (SHOPIFY_API_KEY / SHOPIFY_API_SECRET) comes from shopify app info --web-env.

One-time data migration

# Pull historical data from the legacy SQLite mirror into PostgreSQL
bin/rails db:import_legacy

Run the tests

bin/rails test                # full suite (integration + unit)