Skip to content
This repository has been archived by the owner on Jan 20, 2021. It is now read-only.

tl-its-umich-edu/ocellus

Repository files navigation

hacks_mbof

If you know M-BoF, you don't need to know anything else.

Setup

Use terminal, iTerm, etc. Not XTerm.

  1. Install Vagrant - https://www.vagrantup.com/

  2. Start Vagrant

    • cd ocellus
    • vagrant up
    • vagrant ssh
    • cd /vagrant
  3. Install Bower, Grunt, JsHint and Watch packages

    • cd mbofui
    • bower install
    • npm cache clean
    • npm install
    • grunt dev to lint and concatenate js or grunt js-dev to do the same plus Watch (which concatenates and lints on changes to js)
  4. Prepare the application configuration

  5. Initialize Database

    • cd /vagrant
    • python manage.py migrate
    • python manage.py loaddata mbof/fixtures/dev_data.json
  6. Start the application server

    • Run the development app server
      • Without remote user specified
        • python manage.py runserver
      • With remote user specified
        • sh runAsUser.sh bjensen
          • bjensen is a user included in the test data. Others are available. For the purposes of the HWF event, use only known users.
  7. Browse to...

Update Data Fixtures

This is the procedure for updating the fixture files after adding dummy data to the DB.

  1. Connect to the SQLite DB by opening the db.sqlite3 file with a compatible client. (If a MySQL DB is used for the project later, running in the Vagrant VM, the connection can be made from your host system via the forwarded port defined in the Vagrant file.)
  2. Delete all tables.
  3. Apply the migrations to recreate the tables:
    • python manage.py migrate
  4. Load the existing fixtures:
    • python manage.py loaddata mbof/fixtures/dev_data.json
  5. Make changes to the DB needed to exercise application features.
  6. Save the updated DB to a fixture file:
    • python manage.py dumpdata --indent 4 mbof > mbof/fixtures/dev_data.json
  7. Commit the updated fixture file to the project.

To-Do

  • Display BoFs within viewing area
  • Link BoFs to user
  • get user from api by loginname
  • Create BoF
    • Use REMOTE_USER
    • Set PostingTime and StartTime to current time
    • Set EndTime to five days from current time