diff --git a/README.md b/README.md index 73ba0423d..4da53c2a6 100644 --- a/README.md +++ b/README.md @@ -79,6 +79,12 @@ Paste the link in your browser and you should be able to reset the password. ## Documentation ### Configuration +The configuration of the server is defined in the file +**configuration.template.yml**. All the details are documented there. +You can specify another configuration file by giving it as first argument of +**Authelia**. + + authelia config.custom.yml ### API documentation There is a complete API documentation generated with diff --git a/package.json b/package.json index dc72d2a35..dd715cfea 100644 --- a/package.json +++ b/package.json @@ -3,6 +3,9 @@ "version": "1.0.11", "description": "2-factor authentication server using LDAP as 1st factor and TOTP or U2F as 2nd factor", "main": "src/index.js", + "bin": { + "authelia": "src/index.js" + }, "scripts": { "test": "./node_modules/.bin/mocha --recursive test/unitary", "unit-test": "./node_modules/.bin/mocha --recursive test/unitary", diff --git a/src/index.js b/src/index.js old mode 100644 new mode 100755 index 4717ff2ec..5d967c6f6 --- a/src/index.js +++ b/src/index.js @@ -1,3 +1,4 @@ +#! /usr/bin/env node process.env.NODE_TLS_REJECT_UNAUTHORIZED = "0"; @@ -10,6 +11,12 @@ var nedb = require('nedb'); var YAML = require('yamljs'); var config_path = process.argv[2]; +if(!config_path) { + console.log('No config file has been provided.'); + console.log('Usage: authelia '); + process.exit(0); +} + console.log('Parse configuration file: %s', config_path); var yaml_config = YAML.load(config_path);