Configuration
Setup Lunalytics
Configurations don't need to be setup before starting Lunalytics. But this it is HIGHLY recommended you run the setup script or create a config.json for security reasons. A script can be created by running the following command:
- npm
- yarn
- pnpm
> npm run setup
> yarn setup
> pnpm setup
The following values need to be added to the config.json file:
| Key | Default | Type |
|---|---|---|
| Port | 2308 | Number |
| Database | SQLite | SQLite / PostgreSQL |
| migrationType | automatic | "automatic" / "manual" |
| version | package.json version | String |
| websiteUrl | null | String |
| retentionPeriod | 6m | String |
| register | true | Boolean |
| isDemo | undefined | Boolean |
SQLite config
{
"name": String,
"type": "better-sqlite3"
}
PostgreSQL config
{
"name": String,
"type": "pg",
"config": {
"host": String,
"port": Number,
"user": String,
"password": String
}
}