🌊 A web app for managing membership, training and trips for BSAC branches. 📡 Mirror of https://gitlab.com/wjdp/xSACdb.
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.idea
bin
conf
docs
src
.bashrc
.bowerrc
.codeclimate.yml
.gitignore
.gitlab-ci.yml
CHANGELOG.md
CHECKS
Dockerfile
Gemfile
README.md
app.json
bower.json
gulpfile.js
gunicorn.py
package.json
requirements.txt
requirements_dev.txt
supervisord.conf

README.md

xSACdb

build status Codacy Badge Codacy Badge

A web based database for managing BSAC branch clubs. It looks after membership details, training records, known sites and club trips.

Demo

You can find information about demo instances of the application here: http://xsacdb.wjdp.uk/demo/.

Requirements

  • Linux OS, tested on Ubuntu and Debian
  • Python 2.7
  • virtualenv
  • Bower
  • Sass

Install

xSACdb is a Python web application, it is built on the Django web framework. For production use the only supported deployment method is via Dokku/Docker. See section below.

Install within a virtualenv container, this isolates the dependencies of xSACdb from the rest of your server. If you know what you're doing this'll get you up and running quickly (config needs doing first):

bower install
pip install -r requirements.txt
src/manage.py migrate
src/manage.py reset_fake_db
src/manage.py runserver

You'll also need to run some background task workers with src/manage.py rqworker and a scheduler src/manage.py rqscheduler.

BSAC Data

The application is distributed without any qualifications, lessons or SDCs. I've not fully looked into this but I'm guessing BSAC has copyright on that data. You'll have to put this in yourself.

Deployment

The only supported deployment method is within a predefined Docker container running on a Dokku server. See http://dokku.viewdocs.io/dokku/ for details about setting up a Dokku server. Run the following on the remote.

You will need to make a copy of conf/local_settings.py.example as conf/local_settings.py and define your environment settings and club localisation options.

dokku apps:create xsacdb
dokku plugin:install https://github.com/dokku/dokku-postgres.git
dokku postgres:create xsacdb
dokku postgres:link xsacdb xsacdb
dokku plugin:install https://github.com/dokku/dokku-redis.git redis
dokku redis:create xsacdb
dokku redis:link xsacdb xsacdb
mkdir -p /storage/xsacdb/conf /storage/xsacdb/media
dokku storage:mount xsacdb /storage/xsacdb/conf/:/app/conf/
dokku storage:mount xsacdb /storage/xsacdb/media/:/app/media/

Now on your local machine: obtain the code, add your dokku server as a git remote, and push to deploy.

git clone git@gitlab.com:wjdp/xsacdb.git
cd xsacdb
git checkout master
git remote add deploy dokku@YOUR_DOKKU_SERVER:xsacdb
git push deploy master