MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    Version 2.34.0 - Missing X Server or $DISPLAY (Docker version of MMOS)

    Scheduled Pinned Locked Moved Unsolved Troubleshooting
    15 Posts 3 Posters 310 Views 3 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • M Offline
      Mathes75 @karsten13
      last edited by Mathes75

      @karsten13 New issue. I did the

      cd /opt/mm
      git pull
      ./install/install.sh electron
      

      again and now I’m facing:

      pi@magicmirrorMB:/opt/mm $ ./install/install.sh electron
      
      --> Check docker installation
      
      Docker is already installed:
      Docker version 29.1.3, build f52814d
      Docker Compose version v5.0.1
      Found no xserver or wayland so using own container
      
      --> Pulling container images and starting magicmirror
      
      Going to remove mm
      [+] remove 1/1
       ✔ Container mm Removed                                                                                                                                                            0.1s 
      WARN[0000] No services to build                         
      [+] up 2/2
       ✘ Container labwc Error dependency labwc failed to start                                                                                                                          1.3s 
       ✔ Container mm    Created                                                                                                                                                         0.6s 
      dependency failed to start: container labwc has no healthcheck configured
      

      Don´t know what went wrong.

      Output of docker compose config is:

      pi@magicmirrorMB:/opt/mm/run $ docker compose config
      name: magicmirror
      services:
        labwc:
          container_name: labwc
          environment:
            LAB_WC_HIDE_CURSOR: "true"
            RANDR_PARAMS: ""
            RANDR_POLL: 1m
            XDG_RUNTIME_DIR: /tmp/labwc
          image: karsten13/labwc:latest
          networks:
            default: null
          privileged: true
          restart: always
          volumes:
            - type: bind
              source: /tmp/labwc
              target: /tmp/labwc
              bind: {}
            - type: bind
              source: /run/udev
              target: /run/udev
              bind: {}
        magicmirror:
          container_name: mm
          depends_on:
            labwc:
              condition: service_healthy
              restart: true
              required: true
          environment:
            DISPLAY: unix:0.0
            ELECTRON_ENABLE_GPU: "0"
            MM_CUSTOMCSS_FILE: css/custom.css
            MM_MODULES_DIR: modules
            MM_OVERRIDE_DEFAULT_MODULES: "true"
            MM_SCENARIO: electron
            MM_SHOW_CURSOR: "false"
            WAYLAND_DISPLAY: wayland-0
            XDG_RUNTIME_DIR: /tmp/labwc
          image: karsten13/magicmirror:latest
          network_mode: host
          privileged: true
          restart: always
          shm_size: "268435456"
          volumes:
            - type: bind
              source: /tmp/.X11-unix
              target: /tmp/.X11-unix
              bind: {}
            - type: bind
              source: /home/pi/.Xauthority
              target: /home/node/.Xauthority
              bind: {}
            - type: bind
              source: /tmp/labwc
              target: /tmp/labwc
              bind: {}
            - type: bind
              source: /opt/mm/mounts/config
              target: /opt/magic_mirror/config
              bind: {}
            - type: bind
              source: /opt/mm/mounts/modules
              target: /opt/magic_mirror/modules
              bind: {}
            - type: bind
              source: /opt/mm/mounts/css/custom.css
              target: /opt/magic_mirror/css/custom.css
              bind: {}
          post_start:
            - command:
                - /bin/sh
                - -c
                - |
                  if [ "init" = "init" ]; then
                    # update volume permissions
                    chown -R 1000:1000 config modules css/custom.css
                    chmod -R 777 config modules css/custom.css
                  fi
                  if command -v node_modules/.bin/electron > /dev/null; then
                    # if electron is installed then start dbus-daemon to avoid errors in the logs
                    dbus-daemon --system || true
                  fi
              user: root
      networks:
        default:
          name: magicmirror_default
      
      

      Any way to get back to the easy issue?

      karsten13K 1 Reply Last reply Reply Quote 0
      • karsten13K Online
        karsten13 @Mathes75
        last edited by

        @Mathes75

        looks like you still have an old labwc image, try from /opt/mm/run folder:

        docker compose pull
        docker compose up -d
        
        M 1 Reply Last reply Reply Quote 0
        • M Offline
          Mathes75 @karsten13
          last edited by

          @karsten13
          Back to function! Several restarts without blank screen!

          Output of docker compose config - in case it is useful…

          name: magicmirror
          services:
            labwc:
              container_name: labwc
              environment:
                LAB_WC_HIDE_CURSOR: "true"
                RANDR_PARAMS: ""
                RANDR_POLL: 1m
                XDG_RUNTIME_DIR: /tmp/labwc
              image: karsten13/labwc:latest
              networks:
                default: null
              privileged: true
              restart: always
              volumes:
                - type: bind
                  source: /tmp/labwc
                  target: /tmp/labwc
                  bind: {}
                - type: bind
                  source: /run/udev
                  target: /run/udev
                  bind: {}
            magicmirror:
              container_name: mm
              depends_on:
                labwc:
                  condition: service_healthy
                  restart: true
                  required: true
              environment:
                DISPLAY: unix:0.0
                ELECTRON_ENABLE_GPU: "0"
                MM_CUSTOMCSS_FILE: css/custom.css
                MM_MODULES_DIR: modules
                MM_OVERRIDE_DEFAULT_MODULES: "true"
                MM_SCENARIO: electron
                MM_SHOW_CURSOR: "false"
                WAYLAND_DISPLAY: wayland-0
                XDG_RUNTIME_DIR: /tmp/labwc
              image: karsten13/magicmirror:latest
              network_mode: host
              privileged: true
              restart: always
              shm_size: "268435456"
              volumes:
                - type: bind
                  source: /tmp/.X11-unix
                  target: /tmp/.X11-unix
                  bind: {}
                - type: bind
                  source: /home/pi/.Xauthority
                  target: /home/node/.Xauthority
                  bind: {}
                - type: bind
                  source: /tmp/labwc
                  target: /tmp/labwc
                  bind: {}
                - type: bind
                  source: /opt/mm/mounts/config
                  target: /opt/magic_mirror/config
                  bind: {}
                - type: bind
                  source: /opt/mm/mounts/modules
                  target: /opt/magic_mirror/modules
                  bind: {}
                - type: bind
                  source: /opt/mm/mounts/css/custom.css
                  target: /opt/magic_mirror/css/custom.css
                  bind: {}
              post_start:
                - command:
                    - /bin/sh
                    - -c
                    - |
                      if [ "init" = "init" ]; then
                        # update volume permissions
                        chown -R 1000:1000 config modules css/custom.css
                        chmod -R 777 config modules css/custom.css
                      fi
                      if command -v node_modules/.bin/electron > /dev/null; then
                        # if electron is installed then start dbus-daemon to avoid errors in the logs
                        dbus-daemon --system || true
                      fi
                  user: root
          networks:
            default:
              name: magicmirror_default
          
          
          M 1 Reply Last reply Reply Quote 1
          • M Offline
            Mathes75 @Mathes75
            last edited by

            Pi rebooted twice today (initiated by myself) and issue didn’t come back - I think this can bei marked as resolved - thanks a lot!

            Now I can take care about Python and fritzconnector…

            S 1 Reply Last reply Reply Quote 0
            • S Do not disturb
              sdetweil @Mathes75
              last edited by

              @Mathes75 can you find the message that best explains the fix,
              click the 3 dots to the right and select
              Mark this post as the correct answer

              Sam

              How to add modules

              learning how to use browser developers window for css changes

              1 Reply Last reply Reply Quote 0
              • 1
              • 2
              • 2 / 2
              • First post
                Last post
              Enjoying MagicMirror? Please consider a donation!
              MagicMirror created by Michael Teeuw.
              Forum managed by Sam, technical setup by Karsten.
              This forum is using NodeBB as its core | Contributors
              Contact | Privacy Policy