LifePex/README.md

1.3 KiB

LifePex

Build Status

Dependencies

  • git
  • ruby 3
  • sqlite or postgresql

Setup

# Install dependencies
bundle install

# SQLITE
./init/database.rb sqlite://sqlite.db

# POSTGRESQL
psql -U postgres postgres -c "CREATE USER root WITH PASSWORD 'toor' SUPERUSER;"
psql -U postgres postgres -c "CREATE DATABASE life_pex"
./init/database.rb postgres://root:toor@localhost/life_pex

Start

export LIFEPEX_SECRET="put something random here" # recommanded
export LIFEPEX_BASE_URL="https://mydomain/base" # recommanded
export LIFEPEX_DB="sqlite://sqlite.db" # REQUIRED
# you may also want to use postgres or something
# export LIFEPEX_DB="postgres://root:toor@localhost/life_pex"
# export LIFEPEX_BIND="0.0.0.0" # you may want to bind against something else than 127.0.01
# export LIFEPEX_ENV="production" # why not hide stacktraces ?
./src/app.rb

recap image today image

Generate documentation

./init/doc.rb
xdg-open ./public/doc/index.html

Testing

If you want to run the test, simply type rake test (you will need the startup env variable to be set first).