<liclass="level4"><ahref="#tutorials/running-as-a-service/linux-with-systemd-system-wide">Linux with systemd system-wide</a></li>
<liclass="level4"><ahref="#tutorials/running-as-a-service/linux-with-systemd-as-a-user">Linux with systemd as a user</a></li>
<liclass="level4"><ahref="#tutorials/running-as-a-service/windows-with-nssm---the-non-sucking-service-manager">Windows with "NSSM - the Non-Sucking Service Manager"</a></li>
<liclass="level4"><ahref="#tutorials/reverse-proxy/manage-user-accounts-with-the-reverse-proxy">Manage user accounts with the reverse proxy</a></li>
<liclass="level4"><ahref="#tutorials/reverse-proxy/secure-connection-between-radicale-and-the-reverse-proxy">Secure connection between Radicale and the reverse proxy</a></li>
<p>When everything works, you can get a <ahref="#documentation/supported-clients">client</a> and start creating calendars and address books. The server <strong>only</strong> binds to localhost (is <strong>not</strong> reachable over the network) and you can log in with any user name and password. If Radicale fits your needs, it may be time for <ahref="#tutorials/basic-configuration">some basic configuration</a>.</p>
<p>First, make sure that <strong>python</strong> 3.5 or later (<strong>python</strong>≥ 3.6 is recommended) and <strong>pip</strong> are installed. On most distributions it should be enough to install the package <code>python3-pip</code>.</p>
<divclass="sourceCode"id="cb2"><preclass="sourceCode bash"><codeclass="sourceCode bash"><spanid="cb2-1"><aaria-hidden="true"href="#cb2-1"tabindex="-1"></a><spanclass="co"># Run the following command as root or</span></span>
<spanid="cb2-2"><aaria-hidden="true"href="#cb2-2"tabindex="-1"></a><spanclass="co"># add the --user argument to only install for the current user</span></span>
<p>The first step is to install Python. Go to <ahref="https://python.org">python.org</a> and download the latest version of Python 3. Then run the installer. On the first window of the installer, check the "Add Python to PATH" box and click on "Install now". Wait a couple of minutes, it's done!</p>
<p>Radicale tries to load configuration files from <code>/etc/radicale/config</code> and <code>~/.config/radicale/config</code>. Custom paths can be specified with the <code>--config /path/to/config</code> command line argument or the <code>RADICALE_CONFIG</code> environment variable. Multiple configuration files can be separated by <code>:</code> (resp. <code>;</code> on Windows). Paths that start with <code>?</code> are optional.</p>
<p>You should create a new configuration file at the desired location. (If the use of a configuration file is inconvenient, all options can be passed via command line arguments.)</p>
<p>In its default configuration Radicale doesn't check user names or passwords. If the server is reachable over a network, you should change this.</p>
<p>First a <code>users</code> file with all user names and passwords must be created. It can be stored in the same directory as the configuration file.</p>
<divclass="sourceCode"id="cb4"><preclass="sourceCode bash"><codeclass="sourceCode bash"><spanid="cb4-1"><aaria-hidden="true"href="#cb4-1"tabindex="-1"></a><spanclass="co"># Create a new htpasswd file with the user "user1"</span></span>
<p>The default configuration binds the server to localhost. It can't be reached from other computers. This can be changed with the following configuration options (IPv4 and IPv6):</p>
<p><strong>Security:</strong> The storage folder should not be readable by unauthorized users. Otherwise, they can read the calendar data and lock the storage. You can find OS dependent instructions in the <ahref="#tutorials/running-as-a-service">Running as a service</a> section.</p>
<p>Radicale enforces limits on the maximum number of parallel connections, the maximum file size (important for contacts with big photos) and the rate of incorrect authentication attempts. Connections are terminated after a timeout. The default values should be fine for most scenarios.</p>
<spanid="cb10-9"><aaria-hidden="true"href="#cb10-9"tabindex="-1"></a><spanclass="co"># Average delay after failed login attempts in seconds</span></span>
<p>The method to run Radicale as a service depends on your host operating system. Follow one of the chapters below depending on your operating system and requirements.</p>
<p>Create the <strong>radicale</strong> user and group for the Radicale service. (Run <code>useradd --system --user-group --home-dir / --shell /sbin/nologin radicale</code> as root.) The storage folder must be writable by <strong>radicale</strong>. (Run <code>mkdir -p /var/lib/radicale/collections && chown -R radicale:radicale /var/lib/radicale/collections</code> as root.)</p>
<p>Radicale will load the configuration file from <code>~/.config/radicale/config</code>. You should set the configuration option <code>filesystem_folder</code> in the <code>storage</code> section to something like <code>~/.var/lib/radicale/collections</code>.</p>
<spanid="cb14-5"><aaria-hidden="true"href="#cb14-5"tabindex="-1"></a><spanclass="co"># Check the status of the service</span></span>
<spanid="cb14-6"><aaria-hidden="true"href="#cb14-6"tabindex="-1"></a><spanclass="ex">$</span> systemctl <spanclass="at">--user</span> status radicale</span>
<spanid="cb14-7"><aaria-hidden="true"href="#cb14-7"tabindex="-1"></a><spanclass="co"># View all log messages</span></span>
<h4>Windows with "NSSM - the Non-Sucking Service Manager" <aclass="headerlink"href="#tutorials/running-as-a-service/windows-with-nssm---the-non-sucking-service-manager">¶</a></h4>
<p><strong>Security:</strong> Be aware that the service runs in the local system account, you might want to change this. Managing user accounts is beyond the scope of this manual. Also, make sure that the storage folder and log file is not readable by unauthorized users.</p>
<p>The log file might grow very big over time, you can configure file rotation in <strong>NSSM</strong> to prevent this.</p>
<p>The service is configured to start automatically when the computer starts. To start the service manually open <strong>Services</strong> in <strong>Computer Management</strong> and start the <strong>Radicale</strong> service.</p>
<p>When a reverse proxy is used, the path at which Radicale is available must be provided via the <code>X-Script-Name</code> header. The proxy must remove the location from the URL path that is forwarded to Radicale.</p>
<spanid="cb17-5"><aaria-hidden="true"href="#cb17-5"tabindex="-1"></a><spanclass="co"># Set to directory of .htaccess file:</span></span>
<spanid="cb17-6"><aaria-hidden="true"href="#cb17-6"tabindex="-1"></a>RequestHeader<spanclass="st"> set X-Script-Name /radicale</span></span></code></pre></div>
<p>Be reminded that Radicale's default configuration enforces limits on the maximum number of parallel connections, the maximum file size and the rate of incorrect authentication attempts. Connections are terminated after a timeout.</p>
<h4>Manage user accounts with the reverse proxy <aclass="headerlink"href="#tutorials/reverse-proxy/manage-user-accounts-with-the-reverse-proxy">¶</a></h4>
<p>Set the configuration option <code>type</code> in the <code>auth</code> section to <code>http_x_remote_user</code>. Radicale uses the user name provided in the <code>X-Remote-User</code> HTTP header and disables HTTP authentication.</p>
<spanid="cb19-12"><aaria-hidden="true"href="#cb19-12"tabindex="-1"></a> RequestHeader<spanclass="st"> set X-Script-Name /radicale</span></span>
<spanid="cb19-13"><aaria-hidden="true"href="#cb19-13"tabindex="-1"></a> RequestHeader<spanclass="st"> set X-Remote-User expr=%{REMOTE_USER}</span></span>
<spanid="cb20-10"><aaria-hidden="true"href="#cb20-10"tabindex="-1"></a><spanclass="co"># Set to directory of .htaccess file:</span></span>
<spanid="cb20-11"><aaria-hidden="true"href="#cb20-11"tabindex="-1"></a>RequestHeader<spanclass="st"> set X-Script-Name /radicale</span></span>
<spanid="cb20-12"><aaria-hidden="true"href="#cb20-12"tabindex="-1"></a>RequestHeader<spanclass="st"> set X-Remote-User expr=%{REMOTE_USER}</span></span></code></pre></div>
<p><strong>Security:</strong> Untrusted clients should not be able to access the Radicale server directly. Otherwise, they can authenticate as any user.</p>
<h4>Secure connection between Radicale and the reverse proxy <aclass="headerlink"href="#tutorials/reverse-proxy/secure-connection-between-radicale-and-the-reverse-proxy">¶</a></h4>
<p>SSL certificates can be used to encrypt and authenticate the connection between Radicale and the reverse proxy. First you have to generate a certificate for Radicale and a certificate for the reverse proxy. The following commands generate self-signed certificates. You will be asked to enter additional information about the certificate, the values don't matter and you can keep the defaults.</p>
<p>Radicale is compatible with the WSGI specification.</p>
<p>A configuration file can be set with the <code>RADICALE_CONFIG</code> environment variable, otherwise no configuration file is loaded and the default configuration is used.</p>
<h4>Manage user accounts with the WSGI server <aclass="headerlink"href="#tutorials/wsgi-server/manage-user-accounts-with-the-wsgi-server">¶</a></h4>
<p>Set the configuration option <code>type</code> in the <code>auth</code> section to <code>remote_user</code>. Radicale uses the user name provided by the WSGI server and disables authentication over HTTP.</p>
<h3>Versioning with Git <aclass="headerlink"href="#tutorials/versioning-with-git">¶</a></h3>
<p>This tutorial describes how to keep track of all changes to calendars and address books with <strong>git</strong> (or any other version control system).</p>
<p>The repository must be initialized by running <code>git init</code> in the file system folder. Internal files of Radicale can be excluded by creating the file <code>.gitignore</code> with the following content:</p>
<p>Radicale tries to load configuration files from <code>/etc/radicale/config</code> and <code>~/.config/radicale/config</code>. Custom paths can be specified with the <code>--config /path/to/config</code> command line argument or the <code>RADICALE_CONFIG</code> environment variable. Multiple configuration files can be separated by <code>:</code> (resp. <code>;</code> on Windows). Paths that start with <code>?</code> are optional.</p>
<p>Add the argument <code>--config ""</code> to stop Radicale from loading the default configuration files. Run <code>python3 -m radicale --help</code> for more information.</p>
<p>Path to the CA certificate for validating client certificates. This can be used to secure TCP traffic between Radicale and a reverse proxy. If you want to authenticate users with client-side certificates, you also have to write an authentication plugin that extracts the user name from the certificate.</p>
<p><code>htpasswd</code> : Use an <ahref="https://httpd.apache.org/docs/current/programs/htpasswd.html">Apache htpasswd file</a> to store usernames and passwords.</p>
<p><code>remote_user</code> : Takes the user name from the <code>REMOTE_USER</code> environment variable and disables HTTP authentication. This can be used to provide the user name from a WSGI server.</p>
<p><code>http_x_remote_user</code> : Takes the user name from the <code>X-Remote-User</code> HTTP header and disables HTTP authentication. This can be used to provide the user name from a reverse proxy.</p>
<p>The encryption method that is used in the htpasswd file. Use the <ahref="https://httpd.apache.org/docs/current/programs/htpasswd.html">htpasswd</a> or similar to generate this files.</p>
<p>Available methods:</p>
<p><code>plain</code> : Passwords are stored in plaintext. This is obviously not secure! The htpasswd file for this can be created by hand and looks like:</p>
<p><code>bcrypt</code> : This uses a modified version of the Blowfish stream cipher. It's very secure. The installation of <strong>radicale[bcrypt]</strong> is required for this.</p>
<p><code>md5</code> : This uses an iterated md5 digest of the password with a salt.</p>
<p>The recommended backend is <code>owner_only</code>. If access to calendars and address books outside the home directory of users (that's <code>/USERNAME/</code>) is granted, clients won't detect these collections and will not show them to the user. Choosing any other method is only useful if you access calendars and address books directly via URL.</p>
<p>Command that is run after changes to storage. Take a look at the <ahref="#tutorials/versioning-with-git">Versioning with Git</a> tutorial for an example.</p>
<li><ahref="https://android.com/">Android</a> with <ahref="https://www.davx5.com/">DAVx⁵</a> (formerly DAVdroid)</li>
<li><ahref="https://wiki.gnome.org/Apps/Calendar">GNOME Calendar</a>, <ahref="https://wiki.gnome.org/Apps/Contacts">Contacts</a> and <ahref="https://wiki.gnome.org/Apps/Evolution">Evolution</a></li>
<li><ahref="https://www.mozilla.org/thunderbird/">Mozilla Thunderbird</a> with <ahref="https://addons.mozilla.org/thunderbird/addon/cardbook/">CardBook</a> and <ahref="https://www.mozilla.org/projects/calendar/">Lightning</a></li>
<li><ahref="https://www.inf-it.com/open-source/clients/infcloud/">InfCloud</a>, <ahref="https://www.inf-it.com/open-source/clients/caldavzap/">CalDavZAP</a> and <ahref="https://www.inf-it.com/open-source/clients/carddavmate/">CardDavMATE</a></li>
<p>Many clients do not support the creation of new calendars and address books. You can use Radicale's web interface (e.g. http://localhost:5232) to create and manage address books and calendars.</p>
<p>In some clients you can just enter the URL of the Radicale server (e.g. <code>http://localhost:5232</code>) and your user name. In others, you have to enter the URL of the collection directly (e.g. <code>http://localhost:5232/user/calendar</code>).</p>
<p>Enter the URL of the Radicale server (e.g. <code>http://localhost:5232</code>) and your user name. DAVx⁵ will show all existing calendars and address books and you can create new.</p>
<h4>GNOME Calendar, Contacts and Evolution <aclass="headerlink"href="#documentation/supported-clients/gnome-calendar-contacts-and-evolution">¶</a></h4>
<p><strong>GNOME Calendar</strong> and <strong>Contacts</strong> do not support adding WebDAV calendars and address books directly, but you can add them in <strong>Evolution</strong>.</p>
<p>In <strong>Evolution</strong> add a new calendar and address book respectively with WebDAV. Enter the URL of the Radicale server (e.g. <code>http://localhost:5232</code>) and your user name. Clicking on the search button will list the existing calendars and address books.</p>
<p>Add a new address book on the network with CardDAV. You have to enter the full URL of the collection (e.g. <code>http://localhost:5232/user/addressbook</code>) and your user name.</p>
<p>Add a new calendar on the network with <code>CalDAV</code>. (Don't use <code>iCalendar (ICS)</code>!) You have to enter the full URL of the collection (e.g. <code>http://localhost:5232/user/calendar</code>). If you want to add calendars from different users on the same server, you can specify the user name in the URL (e.g. <code>http://user@localhost...</code>)</p>
<h4>InfCloud, CalDavZAP and CardDavMATE <aclass="headerlink"href="#documentation/supported-clients/infcloud-caldavzap-and-carddavmate">¶</a></h4>
<p>You can integrate InfCloud into Radicale's web interface with <ahref="https://github.com/Unrud/RadicaleInfCloud">RadicaleInfCloud</a>. No additional configuration is required.</p>
<p>Set the URL of the Radicale server in <code>config.js</code>. If <strong>InfCloud</strong> is not hosted on the same server and port as Radicale, the browser will deny access to the Radicale server, because of the <ahref="https://en.wikipedia.org/wiki/Same-origin_policy">same-origin policy</a>. You have to add additional HTTP header in the <code>headers</code> section of Radicale's configuration. The documentation of <strong>InfCloud</strong> has more details on this.</p>
<h4>Command line <aclass="headerlink"href="#documentation/supported-clients/command-line">¶</a></h4>
<p>This is not the recommended way of creating and managing your calendars and address books. Use Radicale's web interface or a client with support for it (e.g. <strong>DAVx⁵</strong>).</p>
<p>To create a new calendar run something like:</p>
<p>The collection <code>/USERNAME</code> will be created automatically, when the user authenticates to Radicale for the first time. Clients with automatic discovery of collections will only show calendars and address books that are direct children of the path <code>/USERNAME/</code>.</p>
<p>Delete the collections by running something like:</p>
<p>This section describes the format of the rights file for the <code>from_file</code> authentication backend. The configuration option <code>file</code> in the <code>rights</code> section must point to the rights file.</p>
<p>The recommended rights method is <code>owner_only</code>. If access to calendars and address books outside the home directory of users (that's <code>/USERNAME/</code>) is granted, clients won't detect these collections and will not show them to the user. This is only useful if you access calendars and address books directly via URL.</p>
<spanid="cb35-7"><aaria-hidden="true"href="#cb35-7"tabindex="-1"></a><spanclass="co"># Allow reading and writing principal collection (same as user name)</span></span>
<spanid="cb35-13"><aaria-hidden="true"href="#cb35-13"tabindex="-1"></a><spanclass="co"># Allow reading and writing calendars and address books that are direct</span></span>
<spanid="cb35-14"><aaria-hidden="true"href="#cb35-14"tabindex="-1"></a><spanclass="co"># children of the principal collection</span></span>
<p>The titles of the sections are ignored (but must be unique). The keys <code>user</code> and <code>collection</code> contain regular expressions, that are matched against the user name and the path of the collection. Permissions from the first matching section are used. If no section matches, access gets denied.</p>
<p>The user name is empty for anonymous users. Therefore, the regex <code>.+</code> only matches authenticated users and <code>.*</code> matches everyone (including anonymous users).</p>
<p>The path of the collection is separated by <code>/</code> and has no leading or trailing <code>/</code>. Therefore, the path of the root collection is empty.</p>
<p>In the <code>collection</code> regex you can use <code>{user}</code> and get groups from the <code>user</code> regex with <code>{0}</code>, <code>{1}</code>, etc.</p>
<p>In consequence of the parameter substitution you have to write <code>{{</code> and <code>}}</code> if you want to use regular curly braces in the <code>user</code> and <code>collection</code> regexes.</p>
<li><strong>R:</strong> read collections (excluding address books and calendars)</li>
<li><strong>r:</strong> read address book and calendar collections</li>
<li><strong>i:</strong> subset of <strong>r</strong> that only allows direct access via HTTP method GET (CalDAV/CardDAV is susceptible to expensive search requests)</li>
<li><strong>W:</strong> write collections (excluding address books and calendars)</li>
<li><strong>w:</strong> write address book and calendar collections</li>
<p>It's safe to access and manipulate the data by hand or with scripts. Scripts can be invoked manually, periodically (e.g. with <ahref="https://manpages.debian.org/unstable/cron/cron.8.en.html">cron</a>) or after each change to the storage with the configuration option <code>hook</code> in the <code>storage</code> section (e.g. <ahref="#tutorials/versioning-with-git">Versioning with Git</a>).</p>
<p>The file system contains the following files and folders:</p>
<ul>
<li><code>.Radicale.lock</code>: The lock file for locking the storage.</li>
<li><code>collection-root</code>: This folder contains all collections and items.</li>
</ul>
<p>A collection is represented by a folder. This folder may contain the file <code>.Radicale.props</code> with all WebDAV properties of the collection encoded as <ahref="https://en.wikipedia.org/wiki/JSON">JSON</a>.</p>
<p>An item is represented by a file containing the iCalendar data.</p>
<p>All files and folders, whose names start with a dot but not <code>.Radicale.</code> (internal files) are ignored.</p>
<p>If you introduce syntax errors in any of the files, all requests that access the faulty data will fail. The logging output should contain the names of the culprits.</p>
<p>Caches and sync-tokens are stored in the <code>.Radicale.cache</code> folder inside of collections. This folder may be created or modified, while the storage is locked for shared access. In theory, it should be safe to delete the folder. Caches will be recreated automatically and clients will be told that their sync-token isn't valid anymore.</p>
<p>You may encounter files or folders that start with <code>.Radicale.tmp-</code>. Radicale uses them for atomic creation and deletion of files and folders. They should be deleted after requests are finished but it's possible that they are left behind when Radicale or the computer crashes. It's safe to delete them.</p>
<p>When the data is accessed by hand or by an externally invoked script, the storage must be locked. The storage can be locked for exclusive or shared access. It prevents Radicale from reading or writing the file system. The storage is locked with exclusive access while the <code>hook</code> runs.</p>
<h5>Linux and MacOS <aclass="headerlink"href="#documentation/storage/locking/linux-and-macos">¶</a></h5>
<p>Use the <ahref="https://manpages.debian.org/unstable/manpages-dev/flock.2.en.html">flock</a> syscall. Python provides it in the <ahref="https://docs.python.org/3/library/fcntl.html#fcntl.flock">fcntl</a> module.</p>
<p>Use <ahref="https://msdn.microsoft.com/en-us/library/windows/desktop/aa365202%28v=vs.85%29.aspx">LockFile</a> for exclusive access or <ahref="https://msdn.microsoft.com/en-us/library/windows/desktop/aa365203%28v=vs.85%29.aspx">LockFileEx</a> which also supports shared access. Setting <code>nNumberOfBytesToLockLow</code> to <code>1</code> and <code>nNumberOfBytesToLockHigh</code> to <code>0</code> works.</p>
<p>To create a new collection, you have to create the corresponding folder in the file system storage (e.g. <code>collection-root/user/calendar</code>). To tell Radicale and clients that the collection is a calendar, you have to create the file <code>.Radicale.props</code> with the following content in the folder:</p>
<p>Calendar and address book collections must not have any child collections. Clients with automatic discovery of collections will only show calendars and address books that are direct children of the path <code>/USERNAME/</code>.</p>
<p>Radicale logs to <code>stderr</code>. The verbosity of the log output can be controlled with <code>--debug</code> command line argument or the <code>level</code> configuration option in the <code>logging</code> section.</p>
<p>Radicale is a small piece of software, but understanding it is not as easy as it seems. But don't worry, reading this short section is enough to understand what a CalDAV/CardDAV server is, and how Radicale's code is organized.</p>
<p>Here is a simple overview of the global architecture for reaching a calendar or an address book through network:</p>
<divclass="tableContainer"><table>
<thead>
<tr>
<th>Part</th>
<th>Layer</th>
<th>Protocol or Format</th>
</tr>
</thead>
<tbody>
<tr>
<tdrowspan="2">Server</td>
<td>Calendar/Contact Storage</td>
<td>iCal/vCard</td>
</tr>
<tr>
<td>Calendar/Contact Server</td>
<td>CalDAV/CardDAV Server</td>
</tr>
<tr>
<td>Transfer</td>
<td>Network</td>
<td>CalDAV/CardDAV (HTTP + TLS)</td>
</tr>
<tr>
<tdrowspan="2">Client</td>
<td>Calendar/Contact Client</td>
<td>CalDAV/CardDAV Client</td>
</tr>
<tr>
<td>GUI</td>
<td>Terminal, GTK, Web interface, etc.</td>
</tr>
</tbody>
</table></div>
<p>Radicale is <strong>only the server part</strong> of this architecture.</p>
<p>Please note that:</p>
<ul>
<li>CalDAV and CardDAV are superset protocols of WebDAV,</li>
<li>WebDAV is a superset protocol of HTTP.</li>
</ul>
<p>Radicale being a CalDAV/CardDAV server, it also can be seen as a special WebDAV and HTTP server.</p>
<p>Radicale is <strong>not the client part</strong> of this architecture. It means that Radicale never draws calendars, address books, events and contacts on the screen. It only stores them and give the possibility to share them online with other people.</p>
<p>If you want to see or edit your events and your contacts, you have to use another software called a client, that can be a "normal" applications with icons and buttons, a terminal or another web application.</p>
<p>The <code>radicale</code> package offers the following modules.</p>
<p><code>__init__</code> : Contains the entry point for WSGI.</p>
<p><code>__main__</code> : Provides the entry point for the <code>radicale</code> executable and includes the command line parser. It loads configuration files from the default (or specified) paths and starts the internal server.</p>
<p><code>app</code> : This is the core part of Radicale, with the code for the CalDAV/CardDAV server. The code managing the different HTTP requests according to the CalDAV/CardDAV specification can be found here.</p>
<p><code>auth</code> : Used for authenticating users based on username and password, mapping usernames to internal users and optionally retrieving credentials from the environment.</p>
<p><code>config</code> : Contains the code for managing configuration and loading settings from files.</p>
<p><code>ìtem</code> : Internal representation of address book and calendar entries. Based on <ahref="https://eventable.github.io/vobject/">VObject</a>.</p>
<p><code>log</code> : The logger for Radicale based on the default Python logging module.</p>
<p><code>rights</code> : This module is used by Radicale to manage access rights to collections, address books and calendars.</p>
<p><code>server</code> : The integrated HTTP server for standalone use.</p>
<p><code>storage</code> : This module contains the classes representing collections in Radicale and the code for storing and loading them in the filesystem.</p>
<p><code>utils</code> : Contains general helper functions.</p>
<p><code>httputils</code> : Contains helper functions for working with HTTP.</p>
<p><code>pathutils</code> : Helper functions for working with paths and the filesystem.</p>
<p><code>xmlutils</code> : Helper functions for working with the XML part of CalDAV/CardDAV requests and responses. It's based on the ElementTree XML API.</p>
<p>The easiest way to develop and install <strong>python</strong> modules is <ahref="https://docs.python.org/3/distutils/setupscript.html">Distutils</a>. For a minimal setup create the file <code>setup.py</code> with the following content in an empty folder:</p>
<p>In the same folder create the sub-folder <code>radicale_static_password_auth</code>. The folder must have the same name as specified in <code>packages</code> above.</p>
<p>Create the file <code>__init__.py</code> in the <code>radicale_static_password_auth</code> folder with the following content:</p>
<spanid="cb40-16"><aaria-hidden="true"href="#cb40-16"tabindex="-1"></a> logger.info(<spanclass="st">"Login attempt by </span><spanclass="sc">%r</span><spanclass="st"> with password </span><spanclass="sc">%r</span><spanclass="st">"</span>,</span>
<p>To make use this great creation in Radicale, set the configuration option <code>type</code> in the <code>auth</code> section to <code>radicale_static_password_auth</code>:</p>
<p>This plugin type is used to check login credentials. The module must contain a class <code>Auth</code> that extends <code>radicale.auth.BaseAuth</code>. Take a look at the file <code>radicale/auth/__init__.py</code> in Radicale's source code for more information.</p>
<p>This plugin type is used to check if a user has access to a path. The module must contain a class <code>Rights</code> that extends <code>radicale.rights.BaseRights</code>. Take a look at the file <code>radicale/rights/__init__.py</code> in Radicale's source code for more information.</p>
<p>This plugin type is used to provide the web interface for Radicale. The module must contain a class <code>Web</code> that extends <code>radicale.web.BaseWeb</code>. Take a look at the file <code>radicale/web/__init__.py</code> in Radicale's source code for more information.</p>
<p>This plugin is used to store collections and items. The module must contain a class <code>Storage</code> that extends <code>radicale.storage.BaseStorage</code>. Take a look at the file <code>radicale/storage/__init__.py</code> in Radicale's source code for more information.</p>
<p>Interested in hacking? Feel free to clone the <ahref="https://github.com/Kozea/Radicale">git repository on GitHub</a> if you want to add new features, fix bugs or update the documentation.</p>
<p>To change or complement the documentation create a pull request to <ahref="https://github.com/Kozea/Radicale/blob/master/DOCUMENTATION.md">DOCUMENTATION.md</a>.</p>
<p>If you want the development version of Radicale, take a look at the <ahref="https://github.com/Kozea/Radicale/">git repository on GitHub</a>, or install it directly with:</p>
<p>It aims to be a lightweight solution, easy to use, easy to install, easy to configure. As a consequence, it requires few software dependencies and is preconfigured to work out-of-the-box.</p>
<p>Radicale is written in Python. It runs on most of the UNIX-like platforms (Linux, *BSD, macOS) and Windows. It is free and open-source software.</p>
<p>CalDAV and CardDAV are not perfect protocols. We think that their main problem is their complexity, that is why we decided not to implement the whole standard but just enough to understand some of its client-side implementations.</p>
<p>CalDAV and CardDAV are the best open standards available, and they are quite widely used by both clients and servers. We decided to use it, and we will not use another one.</p>
<p>Important global development choices have been decided before writing code. They are very useful to understand why the Radicale Project is different from other CalDAV and CardDAV servers, and why features are included or not in the code.</p>
<h5>Oriented to Calendar and Contact User Agents <aclass="headerlink"href="#about//technical-choices/oriented-to-calendar-and-contact-user-agents">¶</a></h5>
<p>Calendar and contact servers work with calendar and contact clients, using a defined protocol. CalDAV and CardDAV are good protocols, covering lots of features and use cases, but it is quite hard to implement fully.</p>
<p>Some calendar servers have been created to follow the CalDAV and CardDAV RFCs as much as possible: <ahref="http://www.davical.org/">Davical</a>, <ahref="http://sabre.io/baikal/">Baïkal</a> and <ahref="http://trac.calendarserver.org/">Darwin Calendar Server</a>, for example, are much more respectful of CalDAV and CardDAV and can be used with many clients. They are very good choices if you want to develop and test new CalDAV clients, or if you have a possibly heterogeneous list of user agents.</p>
<p>Even if it tries it best to follow the RFCs, Radicale does not and <strong>will not</strong> blindly implement the CalDAV and CardDAV standards. It is mainly designed to support the CalDAV and CardDAV implementations of different clients.</p>
<p>Radicale is designed to be simple to install, simple to configure, simple to use.</p>
<p>The installation is very easy, particularly with Linux: one dependency, no superuser rights needed, no configuration required, no database. Installing and launching the main script out-of-the-box, as a normal user, are often the only steps to have a simple remote calendar and contact access.</p>
<p>Contrary to other servers that are often complicated, require high privileges or need a strong configuration, the Radicale Server can (sometimes, if not often) be launched in a couple of minutes, if you follow the <ahref="#tutorials/simple-5-minute-setup">tutorial</a>.</p>
<p>The CalDAV RFC defines what must be done, what can be done and what cannot be done. Many violations of the protocol are totally defined and behaviors are given in such cases.</p>
<p>Radicale often assumes that the clients are perfect and that protocol violations do not exist. That is why most of the errors in client requests have undetermined consequences for the lazy server that can reply good answers, bad answers, or even no answer.</p>
<p>Radicale has been started as a (free topic) stupid school project replacing another (assigned topic) even more stupid school project.</p>
<p>At the beginning, it was just a proof-of-concept. The main goal was to write a small, dirty and simple CalDAV server working with Lightning, using no external libraries. That's how we created a piece of code that's (quite) easy to understand, to use and to hack.</p>
<p>The <ahref="https://github.com/Kozea/Radicale/commit/b1591aea">first lines</a> have been added to the SVN (!) repository as I was drinking (many) beers at the very end of 2008 (Python 2.6 and 3.0 were just released). It's now packaged for a growing number of Linux distributions.</p>
<p>And that was fun going from here to there thanks to you!</p>