hadyrashwan / ruby-sinatra-getting-started

Try out ruby sinatra with sqlite3.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

ruby-sinatra-getting-started

Try out ruby sinatra with sqlite3.

Setup

  • Make sure you have ruby installed.
  • clone the project and run cd ruby-sinatra-getting-started/.
  • Install the packges using bundle install.
  • Run the app using bundle exec ruby server.rb.

APIs

  • Get all the todo items using GET /todo.
  • Add a new item using POST /todo.
  • Update an item using PUT /todo.
  • Delete an item using DELETE /todo.

Todo Model

property Type
id Serial
title String
text String
done Boolean

Deploy on GCP

  • Change the app to use mysql gem instead.
  • Follow the same approach to the ruby-on-rails guide.

About

Try out ruby sinatra with sqlite3.


Languages

Language:Ruby 90.8%Language:Dockerfile 9.2%