Wrong Mountingpoint for one specific Docker Container (Minecraft)

  • Hello,


    today I have tried to create a new minecraft docker container in OMV.

    Everything is running except the mount point.


    In the past I created different docker container and all of them had the right mounting point, only this one not.


    Here is the docker compose file that I use to start the container:


    version: "3.8"


    services:

    mc:

    image: itzg/minecraft-server

    tty: true

    stdin_open: true

    ports:

    - "25565:25565"

    networks:

    VLAN:

    ipv4_address: 192.168.178.11

    environment:

    EULA: "TRUE"

    volumes:

    - ./minecraft:/minecraft

    networks:

    VLAN:

    external: true

    name: "VLAN"




    Usually the mounting point should be in the container folder but every time I start the server it creates a new volume, here are some examples from the last 3 restarts:



    compared to my other container:


    I would like to have the mounted volume in the container folder like for the "asa_server" and the "pihole" container but instead it always creates a new folder with a long folder name.


    I hopye someone can help me.

    Thanks in advanced.

    • Official Post

    I would like to have the mounted volume in the container folder like for the "asa_server" and the "pihole" container but instead it always creates a new folder with a long folder name.

    Why do you want to use named volumes?

    Your compose file is specifying a relative path. I would either git rid of the ./ at the beginng to use a named volume OR the . to CHANGE_TO_COMPOSE_DATA_PATH. I recommend reading the two guides that are linked to in the plugin:


    omv6:docker_in_omv [omv-extras.org]

    omv6:omv6_plugins:docker_compose [omv-extras.org]

    omv 8.0.10-2 synchrony | 6.17 proxmox kernel

    plugins :: omvextrasorg 8.0.2 | kvm 8.0.5 | compose 8.1.3 | cterm 8.0 | borgbackup 8.1.4 | cputemp 8.0 | mergerfs 8.0 | scripts 8.0.1 | writecache 8.1


    omv-extras.org plugins source code and issue tracker - github - changelogs


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

  • I fixed the issues minutes ago.


    the problem was that I renamed the volumes from

    Code
          - ./data:/data

    to

    Code
          - ./minecraft:/minecraft


    after I changed the volume again to the default one it worked.

    I think If you just rename the volume, the docker container will create a temporary folder everytime if I stop and start the container again.

    • Official Post

    I think If you just rename the volume, the docker container will create a temporary folder everytime if I stop and start the container again.

    Nope. You probably just created a new folder "resetting" the container. Volumes are not deleted when you start/stop the container. Their entire idea is to be persistent data that survives container creation and destruction.

    omv 8.0.10-2 synchrony | 6.17 proxmox kernel

    plugins :: omvextrasorg 8.0.2 | kvm 8.0.5 | compose 8.1.3 | cterm 8.0 | borgbackup 8.1.4 | cputemp 8.0 | mergerfs 8.0 | scripts 8.0.1 | writecache 8.1


    omv-extras.org plugins source code and issue tracker - github - changelogs


    Please try ctrl-shift-R and read this before posting a question.

    Please put your OMV system details in your signature.
    Please don't PM for support... Too many PMs!

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!