Linux

Where Does Gonic Store Config and Data?

Gonic configures through env vars, flags, or a config file. Docker keeps the database in /data; systemd uses /etc/gonic plus /var/lib/gonic.

Last updated

Gonic offers three config styles for the same options: GONIC_* environment variables, command-line flags, or a plain config file. Music, podcast, playlist, cache, and database paths plus scan, proxy, and jukebox toggles all exist in each form. Docker composes lean on env vars with volumes for data, music, podcasts, playlists, and cache.

Systemd installs split differently: /etc/gonic/config for settings and /var/lib/gonic for state, running as a dedicated gonic user. The default login is admin/admin, changeable in the web UI after first boot. Multi-folder libraries stack music-path entries (or comma-separated env values), which keeps split collections under one server.

Where Gonic stores this, by platform

Linux
/etc/gonic/config

Settings file for systemd installs (music-path, db-path, cache-path, scan options). State defaults to /var/lib/gonic. Docker instead uses env vars with a /data volume; same options, different spelling.

Linux
/data (Docker volume)

Database, playlists, and working state for Docker installs. Mount persistently with music (ro), podcasts, playlists, and cache beside it. Env vars configure; this volume preserves.

Frequently asked questions

how do i back up gonic docker

Copy the /data volume (database, playlists, cache) and your env/config with the container stopped. Remount music read-only at the same path. Users and play counts travel in the database, so the folder is the backup.

env vars or config file for gonic

Same settings, three spellings. GONIC_MUSIC_PATH (env), -music-path (flag), and music-path (config file) all work. Docker favors env vars; systemd favors /etc/gonic/config. Flags win for one-off overrides.

Notice an outdated path? Let us know.