# Using Dovecot for IMAP

{% hint style="info" %}
Docs are in progress and will be completed soon, this is here in case it's useful to anyone in the meantime.
{% endhint %}

Create a user for Dovecot IMAP:

```
adduser imapguy 
```

In this case, I see the new imapguy user has UID/GID of 1000 in the /etc/passwd file.&#x20;

Add these two lines at the bottom of velocity-install/conf/mta.conf, matching the UID/GID of the imapguy user:

```
Mail Directory UID: 1000
Mail Directory GID: 1000
```

Change the ownership of the mail directory to our Dovecot user.

```
chown -R imapguy.imapguy /root/velocity-install/mail
```

Restart Velocity MTA:&#x20;

```
./restart.sh
```

Future incoming messages will be created with the new UID/GID and readable by Dovecot.
