Engineering
Local setup
How to run the Rails platform and the Expo app. Secrets stay in credentials, not in this wiki.
Open this wiki
open wiki/index.html
Or double-click wiki/index.html. No server needed.
Platform
Rails 8.1 fullstack app in platform/.
Prerequisites
- Ruby 4.0.2 and Bundler
- PostgreSQL
config/master.keyso encrypted credentials can be read
Foreman is installed by bin/dev if missing. Node is not required; Tailwind uses the tailwindcss-rails binary.
Credentials
All environments read PostgreSQL host, port, username, and password from credentials.dig(:database, :production). S3 keys under amazon.s3.
cd platform
bin/rails credentials:edit
Expected shape (values stay in credentials, not in git): database.production, amazon.s3, amazon.ses, amazon.sms, super_user, google, facebook, apple.
config/master.key is gitignored. Without it the app will not boot. Never paste passwords or keys into the wiki.
Databases
| Environment | Name |
|---|---|
| development | taskpaws_development |
| test | taskpaws_test |
| production primary | taskpaws |
| production cache / queue / cable | taskpaws_cache, taskpaws_queue, taskpaws_cable |
Run
cd platform
bin/setup --skip-server
bin/dev
App at http://localhost:3000. Health: GET /up. Jobs: bin/jobs. Tests: bin/rails test and bin/ci.
After SuperUser login: dashboard /admin, staff /admin/users (Impersonate opens /app as that User), super admins /admin/super_users, organizations /admin/organizations (trial days; plan change when subscribed), billing /admin/billing_transactions, roles /admin/roles, actions /admin/actions, audit log /admin/audits, settings /admin/settings.
After staff login: workspace /app, patients /app/patients, schedule /app/schedule, whiteboard /app/whiteboard, catalog /app/catalog, inventory /app/inventory, settings /app/settings (Billing tab: subscribe, upgrade/downgrade, invoices; /app/billing redirects there).
bin/setup installs gems and prepares the database. Pass --reset to rebuild from scratch.
Storage and locales
Active Storage uses S3 (amazon service). English default; Spanish from the marketing nav, /app profile menu, or Admin language menu (cookie) or when Accept-Language prefers es. YAML UI copy lives in en.yml / es.yml; landing plan/feature marketing is edited at Admin /admin/translations. Maintain guide: docs/architecture/translations.md.
Mobile
Expo SDK 57, React 19.2.3, React Native 0.86.2, TypeScript strict. Entry: index.ts → App.tsx.
Prerequisites
- Node.js and npm
- Expo Go on a device, or iOS Simulator / Android Emulator
cd mobile
npm install
npm start
Then npm run ios, npm run android, or npm run web. Native ios/ and android/ are gitignored; generate with Expo prebuild when needed.
App.tsx is the Expo starter. No TaskPaws UI, auth, or API client yet. Implement the first clinic workflow here only after it works on the web and the contract lives in architecture.