BoltCM

Sophisticated, Lightweight and Simple

Jump to docs navigation
Edit on GitHub

Configuration ยป Database Configuration

Bolt supports three different database engines: SQLite, MySQL and PostgreSQL. Each has its benefits and drawbacks.

Not sure which database to use? We suggest using MySQL if available, and SQLite otherwise.

Note: If you've just installed Bolt, you might not have the config.yml-file in app/config yet. You will however have a config.yml.dist-file, in that same directory. The first time Bolt is run, the .yml.dist-files will be automatically copied to .yml-files. If you wish to do some configuration before you first run Bolt, just copy config.yml.dist to config.yml manually.

If you wish to edit the database configuration, you have to change the settings in app/config/config.yml. Apart from SQLite, you can use MySQL and PostgreSQL as database systems. Set the database, username and password:

database:
  driver: mysql
  username: bolt
  password: password
  databasename: bolt

or:

database:
  driver: postgres
  username: bolt
  password: password
  databasename: bolt

Support for PostgreSQL is experimental, so use with caution.

Note: The config file is in the YAML format, which means that the indentation is important. Make sure you leave leading spaces intact.

If the hostname or port are something else than localhost:3306, you can add them like this:

database:
  driver: mysql
  username: bolt
  password: password
  databasename: bolt
  host: database.example.org
  port: 3306

Other settings in the config.yml file can be changed later on, directly from the Bolt backend.

Open your Bolt site in your browser, and you should be greeted by the screen to set up the first user. Do so, and log in to the Bolt Backend. You should now see the (empty) Dashboard screen, and you'll be able to add some dummy pages, using the built-in Loripsum tool. After you've done this, you should see some dummy content, and you're good to go!


Couldn't find what you were looking for? We are happy to help you in the forum, on Slack or on IRC.
Spotted a typo, or have something to add? Edit this page on GitHub.