gitbook2edx-external-grader

0.0.6 • Public • Published

gitbook2edx-external-grader NPM version

external grader engine for edx

Install globally with npm:

npm i -g gitbook2edx-external-grader

General help

Usage:
    gitbook2edx-external-grader serve [ -p PORT ] 
    gitbook2edx-external-grader run [ -e ENGINE ] [ -d | --dry ] CODE 
    gitbook2edx-external-grader -h | --help 

Options:
    -p, --port PORT       port to expose as a push endpoint for edx (def. 1666)
    -e, --engine ENGINE   engine to be used to run scripts ([octave, node])
    -d, --dry             dry run

Arguments:
    CODE                  the code to be executed; default: javascript

Running

The makefile has two targets (start and stop) to make you run the grader in server mode and expose it to the internet. These targets use pm2 to start and stop both the grader and an ngrok server. The ngrok server should be configured with an .ngrok file; this is my ~/.ngrok file:

auth_token: your auth token
tunnels:
    grader:
        subdomain: "grader.cms.zaccaria"
        proto:
            http: 1666

After ngrok started, the server is reachable in this case at: http://grader.cms.zaccaria.ngrok.com. This is the address to use for the Edx push xqueue.

Tests

Tests are categorized in three parts:

  1. Tests for the server part (via supertest); these dont really require app-armor. They just check that data the overall client-server protocol complies with xqueue specs (invoked with make test).
  2. Fake tests for the code-jail environment; these test the sequencing of actions that should be done when launching an application through app-armor, even if you dont have app-armor (e.g., I am developing on a Mac). These are invoked by ./test/test.sh.
  3. App-armor execution; these run some sample scripts under app-armor, by assuming you are under linux 14.04. These are invoked by ./test-local/test.sh

Author

Vittorio Zaccaria

License

Copyright (c) 2015 Vittorio Zaccaria
Released under the BSD license


This file was generated by verb on February 10, 2015.

Dependencies (19)

Dev Dependencies (0)

    Package Sidebar

    Install

    npm i gitbook2edx-external-grader

    Weekly Downloads

    2

    Version

    0.0.6

    License

    BSD

    Last publish

    Collaborators

    • vzaccaria