Skip to content

johnisom/sinatra_cms

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sinatra CMS

This content management system was built with Sinatra on the back-end and uses bcrypt to securely store hashed and salted passwords.

Examples

Signing up, viewing text, markdown, and image files, and creating a file:

Screencast of website part 1

Editing a file multiple times and looking at the restore points:

Screencast of website part 2

Deleting files and unsuccessfully attempting to edit or restore an image file:

Screencast of website part 3

Uploading an image and then duplicating it:

Screencast of website part 4

Features

  • Multiple users
    • Sign in or create own user
    • Securely stores bcrypt salted and hashed passwords in YAML
    • Must be signed in to edit, delete, create, or restore files
  • Create, view, edit, and delete files of any type
  • HTML rendering of markdown files when viewing
  • Photos are rendered normally
  • Version control
    • Every time a change is made to a file, a restore point is created
    • The user can view the restore point before choosing to restore it

Constraints

  • If you’re logged in as any user, you can edit and delete any file
  • No virus or malware checking
  • You can’t edit (including restore) an image file

Installation

  1. Clone this repository (git clone https://github.com/johnisom/sinatra_cms)
  2. cd into the repository (cd sinatra_cms)
  3. Install dependencies (bundle install)
    • If you don’t have ruby-2.6.5, install it
  4. Run the server locally (`bundle exec rackup)
  5. Enjoy your content management system at http://localhost:9292/