docker icon indicating copy to clipboard operation
docker copied to clipboard

Dataloss on restart

Open KDederichs opened this issue 7 years ago • 3 comments

Hey,

I want to use the docker image as development environment but sadly it seems to loose web configuration data on container restart.

I've pretty much used your default docker-compose config:

version: '3.4'
services:
  web:
    image: odoo:11.0
    depends_on:
    - db
    ports:
    - "8069:8069"
    volumes:
      - odoo-web-data:/var/lib/odoo
      - ./modules:/mnt/extra-addons:rw
  db:
    image: postgres:9.4
    environment:
    - POSTGRES_PASSWORD=odoo
    - POSTGRES_USER=odoo
    - PGDATA=/var/lib/postgresql/data/odoo_data
    volumes:
      - db-data:/var/lib/postgresql/odoo_data:rw
volumes:
  db-data: {}
  odoo-web-data: {}

Does anyone know how to fix that?

KDederichs avatar Aug 02 '18 08:08 KDederichs

Can you give more informations ? Do you mean that the volume "odoo-web-data:/var/lib/odoo" is not working ?

d-fence avatar Apr 16 '20 05:04 d-fence

I'm having the same issue when mounting volume to /var/lib/odoo. the container starts but the server does not serve any files. I suspect that the local being empty is what is causing the issue. @d-fence Any idea pls?

mxdev88 avatar Jan 12 '21 18:01 mxdev88

I would look at the examples on https://registry.hub.docker.com/_/odoo/ in detail. If this is no longer an active issue then please close.

lathama avatar Apr 11 '24 15:04 lathama