Server federation and persistant files with docker

Hello everybody,

I’m looking for a tutorial on how to connect my two servers with self-signed certificates.
And how i have to insert and generate this certificates?

Owncloud with Docker

On Both Servers i use Ubuntu 18.04 LTS and the docker installation from the link above.
Where are the f****** persistant files saved on my host system? I am realy to stupid to find them… ? :roll_eyes:

Thanks for your help!!

docker inspect is your friend. It will show you the volumes attached to a container and their mountpoints. The output is JSON, so if you have jq installed you can run the following command:

docker inspect owncloud-container-id(or-name) | jq '.[].Mounts'

Unfortunately, as far as I’m aware, federation doesn’t work fully with self-signed certificates. You can generate the certificates, install them in your web server and then import them with following occ command:

occ security:certificates:import /path/to/cert

This should get you a yellow sign for the federation setup, when you add the servers as trusted servers to each other. This will already allow you to share files between the two servers.
However to get it fully green and have an address book sync you have to run the following and a server with valid SSL certificates:

  1. Set the systems as trusted to each other
  2. Make sure that the cron.php ran on both systems
  3. Run the following two commands on both systems: occ dav:sync-system-addressbook and occ federation:sync-addressbooks

Then the servers should be showing as green in the web interface.
Additionally the commands from step 3 should run regularly perhaps setup as cron job at least once a day.


OK…thanks for the quick reply.
I’m not shure but i think i have to add some another mountpoints to the docker container to make the import of the certification persitant?

That could be the case, I would recommend to try to find out where the occ command saves the certificates and then make sure that path is persistent (it might already be).