You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
You can choose to configure CodiMD with either a config file or with
environment variables. The config file is processed
in lib/config/index.js - so this is the first
place to look if anything is missing not obvious from this document. The
default values are defined in lib/config/default.js,
in case you wonder if you even need to override it.
Environment variables take precedence over configurations from the config files.
To get started, it is a good idea to take the config.json.example and copy it
to config.json before filling in your own details.
Configures Content Security Policy. Directives are passed to Helmet - see their documentation for more information on the format. Some defaults are added to the configured values so that the application doesn't break. To disable this behaviour, set addDefaults to false. Further, if usecdn is on, some CDN locations are allowed too. By default (auto), insecure (HTTP) requests are upgraded to HTTPS via CSP if useSSL is on. To change this behaviour, set upgradeInsecureRequests to either true or false.
Privacy and External Requests
variables
example values
description
allowGravatar
true or false
set to false to disable Libravatar as profile picture source on your instance. Libravatar is a federated open-source alternative to Gravatar.
useCDN
true or false
set to use CDN resources or not (default is true)
Users and Privileges
variables
example values
description
allowAnonymous
true or false
Set to allow anonymous usage (default is true).
allowAnonymousEdits
true or false
If allowAnonymous is true: allow users to select freely permission, allowing guests to edit existing notes (default is false).
allowFreeURL
true or false
Set to allow new note creation by accessing a nonexistent note URL. This is the behavior familiar from Etherpad.
defaultPermission
freely, editable, limited, locked, protected or private
Set notes default permission (only applied on signed-in users).
sessionName
connect.sid
Cookie session name.
sessionLife
14 * 24 * 60 * 60 * 1000 (14 days)
Cookie session life time in milliseconds.
sessionSecret
secret
Cookie session secret. If none is set, one will randomly generated on each startup, meaning all your users will be logged out.
Login methods
Email (local account)
variables
example values
description
email
true or false
Set to allow email sign-in. The default is true.
allowEmailRegister
true or false
Set to allow registration of new accounts using an email address. If set to false, you can still create accounts using the command line - see bin/manage_users for details. This setting has no effect if email is false. The default for allowEmailRegister is true.
Dropbox Login
variables
example values
description
dropbox
{clientID: ..., clientSecret: ...}
An object containing the client ID and the client secret obtained by the Dropbox developer tools
Facebook Login
variables
example values
description
facebook
{clientID: ..., clientSecret: ...}
An object containing the client ID and the client secret obtained by the Facebook app console
GitHub Login
variables
example values
description
github
{clientID: ..., clientSecret: ...}
An object containing the client ID and the client secret obtained by the GitHub developer page. For more details have a look at the GitHub auth guide.