Mobilizon in a docker swarm

When I try to set up a mobilizon instance in a docker swarm (volumes mounted as NFS volume) Mobilizon does not start. When I alter the compose file so that it is just on the local filesystem of the master, it deploys without a hitch. Are there known limitations/issues with having the database on NFS?

Thanks in advance!

Hi,

There should be no issue with NFS as it is pretty transparent for the application.

Do you have any logs ?

There might be some permissions issues.

Have you tried to launch just a database ? I don’t know how PostgreSQL behave with remote file systems …

The problem is that there are no logs. the master, when asked, tells that de containers have started on the worker, the worker however has no containers launched. No logs with ‘docker service logs’ whatsoever. I’ll try to launch just the database and see what happens

Even when I launch the database only, it hangs. This is the part of the compose file that is relevant:

db:
image: docker.io/postgis/postgis:15-3.4
deploy:
mode: replicated
replicas: 1
placement:
constraints:

  • node.role != manager
    volumes:
  • volume_mobilizon_db:/var/lib/postgresql/data
    env_file: /home/.env
    networks:
  • mobilizon-backend

networks:
traefik-test:
external: true
mobilizon-backend:

volumes:
volume_mobilizon_db:
driver: local
driver_opts:
type: nfs
device: :/home/db
o: addr=10.10.0.1,rw,nfsvers=4.2,proto=tcp,timeo=600,retrans=2

One of the problems was the way we mounted, postgres requires ‘sync’ instead of ‘async’ when mounted via NFS, be sure to pass this knowledge along if others come with similar questions. When deployed in a docker swarm, I’m encountering a password problem, so it is still not working on my system.

1 « J'aime »