- Check if "container-selinux" package is present on your system:
```
rpm -qa | grep container-selinux
```
If the above command returns an empty or no output, you should install it via your package manager.
- Check if docker has SELinux support enabled:
```
docker info | grep selinux
```
If the above command returns an empty or no output, create or edit `/etc/docker/daemon.json` and add `"selinux-enabled": true`. Example file content:
```
{
"selinux-enabled": true
}
```
Restart the docker daemon and verify SELinux is now enabled.
This step is required to make sure mailcows volumes are properly labeled as declared in the compose file.
If you are interested in how this works, you can check out the readme of https://github.com/containers/container-selinux which links to a lot of useful information on that topic.
As of June 2022, Docker Compose v1 has been replaced in mailcow by Docker Compose v2. <br>
**Docker Compose v1 will lose official support from Docker in October 2022.**<br>
_mailcow supports Docker Compose v1 until December 2022, after which installation is **imperative** should you wish to **continue** running mailcow._
If you are freshly installing mailcow and have installed Docker in the above way, Docker Compose v2 will already be installed with it. So you don't need to do anything else.
You can check this with `docker compose version`, if the return looks something like `Docker Compose version v2.5.0`, then the new Docker Compose is already installed on your system.
If it is not installed or you want to upgrade from Docker Compose v1 to v2 just follow the instructions:
#### Uninstall Docker Compose v1
To uninstall Docker Compose v1 enter the following command:
```
rm -rf /usr/local/bin/docker-compose
```
#### Install Docker Compose v2
Docker Compose v2 comes with the repository (assuming you followed the instructions at point [installing Docker](#installing-docker)).
Then the installation is quite simple:
```
apt install docker-compose-plugin -y
```
Now type `docker compose version` again and check the return. Is it similar to: `Docker Compose version v2.5.0`? Then everything has been installed correctly!
!!! warning
If you are using an operating system other than Debian/Ubuntu, please take a look at the [official installation manual](https://docs.docker.com/compose/install/#install-compose-on-linux-systems) of Docker itself to learn how to install Docker Compose v2 on other Linux systems.
**1\.** Clone the master branch of the repository, make sure your umask equals 0022. Please clone the repository as root user and also control the stack as root. We will modify attributes - if necessary - while bootstrapping the containers automatically and make sure everything is secured. The update.sh script must therefore also be run as root. It might be necessary to change ownership and other attributes of files you will otherwise not have access to. **We drop permissions for every exposed application** and will not run an exposed service as root! Controlling the Docker daemon as non-root user does not give you additional security. The unprivileged user will spawn the containers as root likewise. The behaviour of the stack is identical.
You may need to stop an existing pre-installed MTA which blocks port 25/tcp. See [this chapter](../post_installation/firststeps-local_mta.en.md) to learn how to reconfigure Postfix to run besides mailcow after a successful installation.
Some updates modify mailcow.conf and add new parameters. It is hard to keep track of them in the documentation. Please check their description and, if unsure, ask at the known channels for advise.
If you do not have an IPv6 enabled network on your host and you don't care for a better internet (thehe), it is recommended to [disable IPv6](../post_installation/firststeps-disable_ipv6.en.md) for the mailcow network to prevent unforeseen issues.
Your data will persist in multiple Docker volumes, that are not deleted when you recreate or delete containers. Run `docker volume ls` to see a list of all volumes. You can safely run `docker compose down` without removing persistent data.