minor formatting

This commit is contained in:
Christoph Haas 2025-08-15 18:46:07 +02:00
parent 47b8c0de12
commit 5eaa855d64
3 changed files with 14 additions and 26 deletions

View file

@ -1,30 +1,21 @@
---
title: Virtual domains
title: SQLite Database
lastUpdated: 2025-08-14
slug: ispmail-trixie/virtual-domains
slug: ispmail-trixie/sqlite
sidebar:
order: 150
order: 155
---
import { Aside } from "@astrojs/starlight/components";
Your mail server will have one fully qualified domain name — for example, `postbox.example.com`. In this case, the base
domain is `example.com`. If someone visits `https://example.com/`, they might be greeted by the Roundcube webmail login
page.
Your mail server must know which domains and email addresses it is responsible for, so it can reject spam sent to
non-existent users. That information will be put into an SQLite database file that will be located at
`/var/vmail/ispmail.sqlite`.
But your server doesnt have to handle only one domain. You might have users like:
<Aside title="What is SQLite?">
SQLite is a lightweight, relational database that stores data in tables with rows and columns, just like bigger
database systems such as MySQL or PostgreSQL. Unlike those, it doesnt need a permanently running server process —
instead, its just a library your application uses directly, storing everything in a single file. This makes it easy
to set up, fast, and ideal for small projects.
</Aside>
- `jack@example.com`
- `lucy@example.com`
- `tina@example.org`
- `jeff@example.net`
These are three different domains, and your server can handle them all.
This is what _virtual domains_ are for. You give your mail server a list of domains and email addresses and it will
receive emails for them. Your users will also have passwords that they need to type in to retrieve their emails. You can
even set up mailing lists that take messages sent to one address and forward them to several users at once.
To make all this work, well store the configuration in a small SQLite database file. Postfix, Dovecot, and Roundcube
will all read from this database to know which domains exist, which users they have, and where each email should go. You
will create that simple database on the next page.