Guide
Configuration is the same as a typical installation of a Rails Engine.
Setup
- Create new Rails app
- Include the Exposition gem by adding
gem 'exposition'
to your Gemfile - Mount the engine by adding
mount Exposition::Engine, at: "/blog"
to the routes file. You can also mount the engine to your project's root by addingmount Exposition::Engine, at: "/"
instead. - Install the migrations by running
rake exposition:install:migrations
- Run the migrations
rake db:migrate
- Add an admin user by using the Rails console
rails exposition:create_user
- Set the values in the en.yml file to your liking
Customization
Frontend styles and markup are where you would expect them to be. So:
- app/views/layouts/exposition/application.html.haml
- app/views/exposition
Admin styles and markup are in the Admin namespace. So:
- app/assets/stylesheets/exposition/admin
- app/views/layouts/exposition/admin.html.haml
- app/views/exposition/admin
You can override these by creating the same files and directory in your app. From there you can customize them however you like
Static Pages
I recommend using High Voltage.
Deployment
You can deploy the app however you like, but I like Heroku. Especially their hobby plan. To deploy on Heroku:
git push heroku master
heroku run rake db:setup
- Create your admin user in the console.
heroku run rails console
rails exposition:create_user
heroku open