Skip to content
forked from carlsonp/kort

A NodeJS application for conducting a variety of UX research methods.

License

Notifications You must be signed in to change notification settings

ScottLogic/kort

 
 

Repository files navigation

Kort

Kort Icon

Build and Test Releases All Downloads License: GPL v3 Known Vulnerabilities Total alerts Language grade: JavaScript

Table of Contents

About
Screenshots
Installation and Setup
After Install
Support / Improvement / Suggestions
License

A web application supporting multiple user experience (UX) research methods.

See the website for more information.

  1. Use one of the following:

    1. Use Git to clone the code (git clone https://github.com/carlsonp/kort.git)
    2. Download a release archive from Github
    3. Install from the published npm package via npm install @carlsonp/kort
  2. Edit app.js and optionally set the adminUser and set your own username.

  3. Edit the adminPassword value in app.js.

  4. Optionally set allowUserRegistration in app.js to allow users to register. Otherwise users can only be created by accounts with 'admin' access.

  5. Optionally setup Google authentication. See the wiki for details.

  6. Continue installation via source or via Docker.

  1. Install Node.js

  2. Install MongoDB (3.0 or higher) or provide a connection to an existing server by editing the app.js file and setting the mongoURL. Kort uses the Mongoose package. To optionally secure your MongoDB with a username and password, create a user for the kort database by doing the following:

    Open a Mongo commandline shell:

    mongo --port 27017

    Select the database:

    use kort
    

    Create the new user:

    db.createUser(
       {
         user: "kort",
         pwd: "123",
        roles: [ { role: "readWrite", db: "kort" } ]
       }
    )
    

    Then edit /etc/mongodb.conf and enable auth=true. Restart the service. Make sure to set the mongoURL with the appropriate username and password.

  3. Run npm install on the commandline. This will install the dependencies into the node_modules folder.

  4. Run npm run build on the commandline. This will setup browserify bundle, which is needed for browser imports of modules. You will see bundle.js in the dist folder.

  5. Run node app.js from the main directory. This will start the NodeJS server on the default port 3000.

  1. Install Docker

  2. Install docker-compose

  3. Ensure you create a .env file in the root of the project directory with the required environment variables (See example.env). If you choose to set the environment variables directly, remove any refences to the .env file in docker-compose.yml to prevent docker compose looking for it at build time.

    If you wish to secure the connection between the kort and mongo containers, uncomment the MONGO_INITDB_ROOT_USERNAME, MONGO_INITDB_ROOT_PASSWORD, MONGO_INITDB_DATABASE, MONGO_KORT_USERNAME and MONGO_KORT_PASSWORD values in the .env file and define the required credentials.

    If you need to specify connection options for the connection from the kort to the mongo containers, uncomment the MONGO_OPTIONS value in the .env file and define the required connection options in url parameter format.

  4. Build the containers

    docker-compose build
  5. Start the containers (use -d to run in detached mode)

    docker-compose up
  6. Stop the containers (when using detached mode)

    docker-compose down

Data from MongoDB is persisted and mounted as a Docker volume in the ./data/ folder.

  1. You can connect via http://localhost:3000

  2. The admin username and password for Kort can be set using environment variables KORT_ADMIN_USER and KORT_ADMIN_PASSWORD. These can be set in the .env file or directly as environment variables. Please note that if you define these variables using both methods, the environment variables will take precedence. If the variables are not set, then a default usename and password of admin/admin will be used.

  3. The RATE_LIMIT variable relates to the maximum number of requests that the server will allow over a 10 second period. By default the rate is set at 120. This can be edited in the .env file or as an environment variable. Please note that if you define these variables using both methods, the environment variables will take precedence. Please note this rate includes any requests the application makes to serve the ui pages such as css and js files, and can make over 20 requests per page.

  4. The ENVIRONMENT variable controls the Helmet settings. When the variable is set to development, we override certain security headers to facilitate load testing. In any other mode, it defaults to production and applies the strict security headers defined by Helmet.

Open a Github issue.

Kort is licensed under the GPLv3.

About

A NodeJS application for conducting a variety of UX research methods.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 66.6%
  • EJS 30.0%
  • CSS 3.1%
  • Dockerfile 0.3%