Thanks to @MichMich and his outstanding installation script, installing MagicMirror² is pretty straight forward.
After you’ve configured and updated your Raspberry Pi and rebooted, launch a Terminal window again and type in
bash -c "$(curl -sL https://raw.githubusercontent.com/MichMich/MagicMirror/master/installers/raspberry.sh)"
This will start the installation process for you:
A few configurations still need to be done on the Raspberry Pi, specific for MagicMirror². Let’s start with rotating the display vertically. For this, you’ll need to edit one of the boot configurations. (Please note: If you plan on running MagicMirror² as a landscape (or wide) display, you do not need to do this.)
Type in sudo nano /boot/config.txt and add the following to the file. Where you add it doesn’t really matter:
# Rotate display vertically
Press CTRL-X when you’re done, and say Y(es) to saving the changes.
Let’s disable the screen saver and screen blanking as well. This needs to be done in two places. First in the autostart configuration:
sudo nano /etc/xdg/lxsession/LXDE-pi/autostart
And add the following to the bottom of the file:
@xset s noblank
@xset s off
Next in the X-windows manager configuration:
sudo nano /etc/lightdm/lightdm.conf
Scroll down to the [SeatDefaults] section and look for the xserver-command line below that. Change the line to look like this:
xserver-command=X -s 0 -dpms (so you’re removing the # on the front, and adding the missing bits at the end.) Again, hit CTRL-X and say Y(es) to saving the file.
A Raspberry Pi is configured to automatically shutdown parts of the hardware that aren’t actively in use. This includes the WiFi driver. This will cause MagicMiror² to occasionally fail to fetch updates for things like the newsfeed, weather, and others. You can disable the power saving feature for the WiFi from the interfaces configuration file:
sudo nano /etc/network/interfaces
Find the wlan0 section and add wireless-power off below it:
Once you’re done with that, reboot the rpi one more time with sudo reboot and when it comes back up again, open a Terminal window and type in iwconfig and you should see that the Power Management is now off:
At this point you have completed the basic install for MagicMirror². The next step is to create a valid configuration file for it so you can test it out. You can do that by going into the MagicMirror’s config folder:
pi@magicpi:~ $ cd MagicMirror/config
pi@magicpi:~/MagicMirror/config $ cp config.js.sample config.js
You can now try to start MagicMirror².
pi@magicpi:~/MagicMirror/config $ cd $HOME/MagicMirror
pi@magicpi:~/MagicMirror $ npm start
If everything went well, your screen should load up the MagicMirror² interface. The weather module will tell you that you don’t have a valid APPID, but once set, your screen should look like this: