@delightedcrow Thanks for the quick reply.
I will send them an email to check how the random feature is implemented.
Read the statement by Michael Teeuw here.
Posts
-
RE: First MagicMirror
-
RE: First MagicMirror
Dear @delightedcrow,
thank you very much for this beautiful theme. I really like using WallberryTheme to beautify the background of my screen.
What strikes me is that the images do not seem to be truly random. I have linked it up to a bigger collection and keep seeing the same images over and over although statistically, this should not be the case. Did you experienced this as well?Thanks!
-
RE: Update says to "commit your changes or stash them before you can merge." ?
I am trying to update my Docker version to 2.5.0. Do I need to update the Docker image itself or can I just use the regular update path?
I keep getting the error to commit or stash my changes. Doing so does not change a thing:
root@magic_mirror:/opt/magic_mirror# git reset --hard && git pull HEAD is now at 6aa156d Merge pull request #1343 from MichMich/develop Updating 6aa156d..6db61b4 error: Your local changes to the following files would be overwritten by merge: config/config.js.sample css/main.css modules/default/alert/alert.js modules/default/calendar/calendarfetcher.js modules/default/compliments/README.md modules/default/compliments/compliments.js modules/default/newsfeed/README.md modules/default/newsfeed/newsfeed.js modules/default/updatenotification/updatenotification.js modules/default/weatherforecast/weatherforecast.js Please, commit your changes or stash them before you can merge. Aborting ``` Stashing the changes does not help either. Does someone have an idea? -
RE: Electron Error: Cannot open display :0
@bream @sdetweil Thank you very much for your reply! This could be the right path! I have initially configured the Pi on the GUI surface (Wifi, Keyboard) and then switched to CLI boot. I have done this with my previous installations of MagicMirror without problems, as electron started the x-server as needed. This does not seem to work anymore…
How do I revert this? I have changed back from CLI-boot to Desktop GUI in raspi-config. If I ssh into the pi and start MagicMirror via
DISPLAY=:0 npm start, the application claims to start without problems:> magicmirror@2.5.0 start /home/pi/MagicMirror > sh run-start.sh Starting MagicMirror: v2.5.0 Loading config ... Loading module helpers ... No helper found for module: alert. Initializing new module helper ... Module helper loaded: updatenotification No helper found for module: clock. Initializing new module helper ... Module helper loaded: calendar No helper found for module: compliments. No helper found for module: currentweather. No helper found for module: weatherforecast. Initializing new module helper ... Module helper loaded: newsfeed All module helpers loaded. Starting server on port 8080 ... Server started ... Connecting socket for: updatenotification Connecting socket for: calendar Starting node helper for: calendar Connecting socket for: newsfeed Starting module: newsfeed Sockets connected & modules started ... Launching application.Unfortunately, the display still just shows the GUI of the operation system.
Could you please help me from here?Thank you very much!
-
Electron Error: Cannot open display :0
Dear all,
I have tried to setup MM2 about 20 times by now and always run into exactly the same error:pi@MirrorPi:~ $ cd MagicMirror/ pi@MirrorPi:~/MagicMirror $ DISPLAY=:0 npm start > magicmirror@2.5.0 start /home/pi/MagicMirror > sh run-start.sh (electron:24936): Gtk-WARNING **: cannot open display: :0 npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! magicmirror@2.5.0 start: `sh run-start.sh` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the magicmirror@2.5.0 start script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! /home/pi/.npm/_logs/2018-10-03T21_35_33_903Z-debug.logThe Log-File states:
info it worked if it ends with ok 1 verbose cli [ '/usr/bin/node', '/usr/bin/npm', 'start' ] 2 info using npm@6.4.1 3 info using node@v10.11.0 4 verbose run-script [ 'prestart', 'start', 'poststart' ] 5 info lifecycle magicmirror@2.5.0~prestart: magicmirror@2.5.0 6 info lifecycle magicmirror@2.5.0~start: magicmirror@2.5.0 7 verbose lifecycle magicmirror@2.5.0~start: unsafe-perm in lifecycle true 8 verbose lifecycle magicmirror@2.5.0~start: PATH: /usr/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/home/pi/MagicMirror/node_modules/.bin:/usr/local/sb$ 9 verbose lifecycle magicmirror@2.5.0~start: CWD: /home/pi/MagicMirror 10 silly lifecycle magicmirror@2.5.0~start: Args: [ '-c', 'sh run-start.sh' ] 11 silly lifecycle magicmirror@2.5.0~start: Returned: code: 1 signal: null 12 info lifecycle magicmirror@2.5.0~start: Failed to exec start script 13 verbose stack Error: magicmirror@2.5.0 start: `sh run-start.sh` 13 verbose stack Exit status 1 13 verbose stack at EventEmitter.<anonymous> (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:301:16) 13 verbose stack at EventEmitter.emit (events.js:182:13) 13 verbose stack at ChildProcess.<anonymous> (/usr/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14) 13 verbose stack at ChildProcess.emit (events.js:182:13) 13 verbose stack at maybeClose (internal/child_process.js:962:16) 13 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:251:5) 14 verbose pkgid magicmirror@2.5.0 15 verbose cwd /home/pi/MagicMirror 16 verbose Linux 4.14.70-v7+ 17 verbose argv "/usr/bin/node" "/usr/bin/npm" "start" 18 verbose node v10.11.0 19 verbose npm v6.4.1 20 error code ELIFECYCLE 21 error errno 1My setup process is:
- clean install of latest image of Raspian stretch
- setup wifi, keyboard, CLI-boot
- sudo apt-get update && sudo apt-get upgrade
- set memory-split to 256
- activate Fake KMS
- install latest versions of NodeJS (via apt-get) and npm (via npm)
- install MM2 via raspberry.sh script
I do not get any error messages during setup.
I also tried the manual setup several times with the same result and even tried different Pis, SD cards and Monitors. Setting up the system on-site or via SSH does not make a difference either.
Searching the internet did not get me very far. What I tried without success:
export DISPLAY=":0.0"export DISPLAY=":0"xhost +–> unable to open display “:0”xhost local:root--> unable to open display “:0”xhost +localhost--> unable to open display “:0”- adding
Defaults env_keep=DISPLAYin /etc/sudoers - adding
export XAUTHORITY=$HOME/.Xauthorityin /home/pi/.bashrc
Do you have any idea how to solve this?
-
RE: Installing the dependencies - Can't finish the installation.
@magicmirrork Did you eventually solve this? I got the same problem yesterday :(
-
RE: Access control
@retroflex Thanks for the idea. I think this is a possible option for many - but I already have the company VPN on my devices and unfortunately cannot add another VPN.
Do you think it would be difficulty to implement the token-idea I described above? This would bring much more security to a lot of users without difficult changes…
-
Access control
Dear all,
is there a way to control access to the Magic Mirror next to whitelisting IPs? I would like to use a MagicMirror as info-screen for my commuting and thus need to access it also when I am at my office and want to go home.Of course, if I open the port to the Internet, everyone can access my MagicMirror-Website. Is there a way to limit access only to selected viewers, maybe by passing along a secret token with the URL (
http://myMagicMirror:8080?secretToken=myAccessToken)?Thanks a lot for your help!
-
RE: black screen with "node clientonly"
I think I found the solution: When starting MM inside Docker, I cannot add the true address (172.1.0.9) into the config file but leave it like this:
address: "", // LocalhostI can open this Docker-hosted Magic Mirror Website directly using a browser without problem.
I am not yet versed in JS, but I had a look at the config.js in the clientonly-folder: There is this section, where the config from the remote server is received and passed along as environment variable:
getServerAddress(); (config.address && config.port) || fail(); // Only start the client if a non-local server was provided if (["localhost", "127.0.0.1", "::1", "::ffff:127.0.0.1", undefined].indexOf(config.address) === -1) { getServerConfig(`http://${config.address}:${config.port}/config/`) .then(function (config) { // Pass along the server config via an environment variable var env = Object.create(process.env); var options = { env: env }; config.address = config.address; config.port = config.port; env.config = JSON.stringify(config);It seems, that the
addressinformation received from the server (which is empty in my case) overwrites theconfig.addressvariable I passed along when startingnode clientonly --address 192.0.0.95 --port 9090. I changed the code manually and it worked :slightly_smiling_face:@MichMich I have added a pull request on Github to help others with the same problem (https://github.com/MichMich/MagicMirror/pull/1403)
PS: The error message describe above remains, but the Magic Mirror shows up without problem.