Mailcow-dockerized: Installing RainLoop web mail

Created on 17 Sep 2017  路  6Comments  路  Source: mailcow/mailcow-dockerized

I tried installing RainLoop by doing the following:

cd ~/mailcow-dockerized/data/web/
mkdir rainloop && cd rainloop
wget https://www.rainloop.net/repository/webmail/rainloop-community-latest.zip
unzip rainloop-community-latest.zip

Then, I go into my browser to mymailserver.com/rainloop and I get this error:

[105] Missing version directory

From a little bit of research, this seems like a permissions error so I do the following:

sudo chmod -R 755 ~/mailcow-dockerized/data/web/rainloop/

The first error is gone, however, now I have this error:

[202] Data folder permissions error [is_writable]

I tried a few different things such as chowning my rainloop directory recursively as www-data, but that did not work either.

Any idea what I am doing wrong?

Also, to be clear, this seems to be some PHP file creation error.

I troubleshooted by creating a file named test.php with the following code:

<?php
mkdir("test-folder")

When I visited this file in my browser, I got the error: Warning: mkdir(): Read-only file system in /web/rainloop/test.php on line 2

Most helpful comment

Figured it out!

First, I needed to find the id of the Docker phpfpm module, so I did the following:

docker ps | grep fpm

You'll see an ID next to the mailcow/phpfpm module. Copy it.

The I accessed that module by entering:

docker exec -it d01010101010 bash

Note: Replace d01010101010 with your phpfpm's module ID.

Then, type id www-data.

Copy the UID value. Mine was 82.

Type exit.

Then, type sudo chown -R 82 your/path/to/data/web/.

Obviously, replace your/path/to/data/web/ to your actual Mailcow data/web folder.

Finally, type sudo chgrp -R docker data/web/.

That worked for me.

All 6 comments

You would need to change docker-compose.yml =>

    php-fpm-mailcow:
      image: mailcow/phpfpm:1.1
      build: ./data/Dockerfiles/phpfpm
      command: "php-fpm -d date.timezone=${TZ}"
      depends_on:
        - redis-mailcow
      volumes:
        - ./data/web:/web:rw

Last line: ro to rw

Awesome, thank you!

Very odd. I am still getting the same error. I even rebooted my server.

Figured it out!

First, I needed to find the id of the Docker phpfpm module, so I did the following:

docker ps | grep fpm

You'll see an ID next to the mailcow/phpfpm module. Copy it.

The I accessed that module by entering:

docker exec -it d01010101010 bash

Note: Replace d01010101010 with your phpfpm's module ID.

Then, type id www-data.

Copy the UID value. Mine was 82.

Type exit.

Then, type sudo chown -R 82 your/path/to/data/web/.

Obviously, replace your/path/to/data/web/ to your actual Mailcow data/web folder.

Finally, type sudo chgrp -R docker data/web/.

That worked for me.

ID and UID would change every time we restart the machine or docker down/up, right @DougBeney ?

Not completely sure. I have restarted my server before and I didn't run into the same problem.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

RogerSik picture RogerSik  路  3Comments

starcraft0429 picture starcraft0429  路  3Comments

lgleim picture lgleim  路  3Comments

thannaske picture thannaske  路  3Comments

GalacticLion7 picture GalacticLion7  路  3Comments