Since the “legacy” unifi controler docker container from linuxServer will be deprecated and the new " unifi network application " requires a external MongoDB to operate , i will need to remove my old container and install these plus a mongo db . But i fail to understand how to instal / populate the DB as pere their guide .
If someone has done it and is willing to share a guide or tips id be glad.

  • janjaweedIntifada@alien.topB
    link
    fedilink
    English
    arrow-up
    2
    ·
    11 months ago

    here is my docker compose. change env as needed. I used mongo express.

    unifi:
    image: lscr.io/linuxserver/unifi-network-application:latest
    container_name: unifi
    depends_on:
    - mongo
    #- mongo-express
    environment:
    - PUID=1000
    - PGID=1000
    - TZ=Etc/UTC
    - MONGO_USER=${POSTGRES_USER}
    - MONGO_PASS=${POSTGRES_PASSWORD}
    - MONGO_HOST=mongo
    - MONGO_PORT=27017
    - MONGO_DBNAME=unifi
    - MEM_LIMIT=1024 #optional
    - MEM_STARTUP=1024 #optional
    volumes:
    - /docker/unifi/data:/config
    ports:
    - 8443:8443
    - 3478:3478/udp
    - 10001:10001/udp
    - 8080:8080
    - 1900:1900/udp #optional
    - 8843:8843 #optional
    - 8880:8880 #optional
    - 6789:6789 #optional
    - 5514:5514/udp #optional
    restart: unless-stopped
    ##############################################################
    mongo:
    container_name: mongo
    image: mongo
    restart: unless-stopped
    #environment:
    #- MONGO_INITDB_ROOT_USERNAME:${POSTGRES_USER}
    #- MONGO_INITDB_ROOT_PASSWORD:${POSTGRES_PASSWORD}
    volumes:
    - /docker/mongo/data:/data/db
    - /docker/mongo/init-mongo.js:/docker-entrypoint-initdb.d/init-mongo.js:ro