> For the complete documentation index, see [llms.txt](https://gotolabs.gitbook.io/lightninguservault/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://gotolabs.gitbook.io/lightninguservault/getting-started/server-commands.md).

# Server Commands

Welcome to the Server Commands page for LightningUserVault. Here, you'll find a comprehensive list of commands to help you start and configure the web server. Let's dive in!

**GENERAL SERVER SETTINGS**

* `SERVER_ADDRESS`: Address for your web server. Default: `0.0.0.0:8080`
* `LOG_LEVEL`: Set the type of logs you want to see. Options include `ERROR`, `INFO`, `DEBUG`, and `WARN`. Default: `WARN`

**STORAGE SETTINGS**

To determine how your data is stored, use the following:

* `STORAGE_TYPE`: Choose between:
  * `PEBBLE` (default)
  * `POSTGRESQL`

**Postgres Settings** (Only applicable if `STORAGE_TYPE=POSTRESQL`):

* `DB_HOST`: Address of your database host. Default: `postgres:5432`
* `DB_USER`: Username for your database. Default: `postgres`
* `DB_PASS`: Password for your database user. Default: `postgres`
* `DB_NAME`: Name of your database. Default: `postgres`

**CACHE SETTINGS**

Manage your caching preferences with:

* `ENABLE_CACHE`: Decide if you want to enable caching. Default: `true`

If `ENABLE_CACHE=false`, the following commands won't be used:

* `CACHE_TYPE`: Type of cache to use. Default: `MEMCACHE`
* `MEMCACHE_ADDRESS`: Address for the memcache server. Default: `memcached:11211`

**Using the CLI Flags**

For those who prefer command-line flags, here they are:

* `--log-level`: Set the log level
* `--server-address`: Define the server endpoint
* `--enable-cache`: Enable or disable cache
* `--cache-type`: Choose the cache type
* `--memcache-address`: Set the memcache endpoint
* `--storage-type`: Select the storage type
* `--database-host`: Define the database host endpoint
* `--database-user`: Specify the database user
* `--database-pass`: Set the database password
* `--database-name`: Name your database

**Environment File Support**

LightningUserVault supports environment files. If you set a flag inside the environment file, it will take priority over any CLI flag.&#x20;

Here's a template for your environment file:

```markup
LOG_LEVEL=
SERVER_ADDRESS=
ENABLE_CACHE=
CACHE_TYPE=
MEMCACHE_ADDRESS=
STORAGE_TYPE=
DB_HOST=
DB_USER=
DB_PASS=
DB_NAME=
```
