Operations
Daily tasks and command-line shortcuts for running the shop's back office.
Rake tasks
bin/rails ops:sync # full Shopify + Square sync
bin/rails ops:sync_source[square] # single source
bin/rails ops:catalog_links # read-only catalog identity audit
bin/rails ops:sqlite:report # SQLite configuration and space metrics
bin/rails ops:sqlite:optimize # refresh planner statistics
bin/rails test # page + API smoke tests
Scheduled work
Syncs and backups run through Solid Queue (bin/jobs):
- Sync tenants — every 15 minutes in production (schedule in
config/recurring.yml) - Drive backups — one whole-instance upload every 6 hours when the platform connection is configured, keeping 7 snapshots by default
- Finished-job cleanup — hourly
Shipping desk workflow
- Open the Sales journal and click any order number to open it.
- Print an invoice or packing slip from the order page.
- Use Add shipment to record the carrier and tracking number — the order is marked fulfilled and the tracking number becomes a deep link.
- With the (off-by-default) fulfillment workflow enabled in Settings, advance the order through in-transition / shipped / arrived / completed.
Backups
Two whole-database backup paths exist on the Settings page for platform administrators. Both contain every workspace in the instance:
- Database backup — download a consistent adapter-aware SQLite snapshot or PostgreSQL
pg_dump, or restore from a previous upload. - Google Drive backup — a platform administrator explicitly configures instance credentials in Settings → Environment and completes Google consent for the destination. Trusted host configuration can also supply these values. Status, history and disconnect controls are platform-only. Scheduled uploads run once per instance every 6 hours when connected, keeping 7 snapshots by default.
Existing workspace-owned Drive settings and connections are ignored; they are never automatically migrated or approved. Disconnect disables the instance connection, including any refresh token supplied by host configuration. Local snapshot timers run independently of this connection; an upload history entry alone is not proof of a tested restore.
Known caveats
- The Shopify sync uses a client-credentials token (
SHOPIFY_CLIENT_ID/SHOPIFY_CLIENT_SECRET). If it's rejected, re-install the app or regenerate the secret in the Shopify admin — the sync fails loudly on the Sync page until then. - Fulfillment sync requires the
read_fulfillments/write_fulfillmentsscopes, which prompt for re-consent on next app install.