bucky 4a82174526 implemented API create endpoint
+ added plugins to read json and access the header to parse the request
  for an API request
+ fixed logic where url param is nil
+ refactored the new code to a variable to be reused easier
+ if CONTENT_TYPE header is application/json, reply with json
- there could be more refactoring (maybe separating it to a different
  endpoint) to handle other scenarios, we'll work on that later
2023-10-11 19:21:43 -07:00
2023-10-11 19:21:21 -07:00
2023-10-11 19:21:43 -07:00
2023-10-06 18:07:07 -07:00

simple url shortener

this project is a simple solution to build out a URL shortener using Roda, Falcon, Sequel, and SQLite

the point of this project is to quickly build something and work on continuous deployment while making small refinements to the functional pieces.

the outside pieces of software that this project relies on are sqlite3 and pkgconf.

first you have to install the dependencies:

bundle install

if you want the development group included run this first:

bundle config set --local with 'development'

then create a .env.rb file in the root directory that contains the following ENV attributes:

ENV["APP_SESSION_SECRET"] = {output of a random 64 byte secret}

ENV["DB_NAME"] = {db file name}

after the dependencies are installed, you have to create the db

sequel -m db/migrations sqlite://db/{DB_NAME}

to start the application with Falcon:

rackup -o {ip address} -p {port} -s falcon

S
Description
No description provided
Readme 360 KiB
2023-10-15 Latest
2023-10-15 12:03:17 -07:00
Languages
Ruby 60.3%
HTML 21.8%
Gherkin 17.9%