Beyarz / Menu-backend

Backend repo for a frontend app using Rails api only mode

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Backend

Backend repo for the Menu app, using rails api mode. The data loaded into the db is not real and only used for prototyping. The indexing is done through Searchkick & Opensearch (fork of Elasticsearch).

Requirements

  • Ruby 3.1.2
  • Rails 7
  • Docker

Getting started

chmod +x bin/docker-entrypoint.sh

Local rails development

bundle
rails db:migrate
rails db:seed
rails server

Remote container development (recommended for Windows)

docker compose -f docker-compose.dev.yml up

Development notes

See dev.md

Troubleshoot

exception": "#<Searchkick::MissingIndexError: Index missing - run Menu.reindex>"

Run: rake searchkick:reindex CLASS=Menu inside the container or in your terminal

Improvement

  • Add compose service for production
  • Write proper tests

About

Backend repo for a frontend app using Rails api only mode


Languages

Language:Ruby 99.5%Language:Shell 0.5%