Post

Homer Install - Ubuntu 22.04

Homer is a full static html/js dashboard, based on a simple yaml configuration file. See documentation for information about the configuration (assets/config.yml) options. It’s meant to be served by an HTTP server, it will not work if you open the index.html directly over file:// protocol.

Install Nginx

First, update the repo to get latest versions and install Nginx:

1
2
sudo apt update
sudo apt install nginx -y

Enable the service to start on boot

1
sudo systemctl enable nginx

Installing Homer Dashboard

First download the latest release from the github repo. From your home directory run the following:

1
wget "https://github.com/bastienwirtz/homer/releases/latest/download/homer.zip"

Next, extract homer into the Nginx folder:

1
sudo unzip homer.zip -d /var/www/html

If the above command fails because you haven’t got unzip intalled, use the following to install, then re-run the above command.

1
sudo apt install unzip

Amend the permissions on the homer folder:

1
sudo chown www-data:www-data /var/www/html/ -R

Get the default config from Homer dist:

1
sudo cp /var/www/html/assets/config.yml.dist /var/www/html/assets/config.yml

Configure Nginx

1
sudo nano /etc/nginx/sites-enabled/default

Remove the config in the file (use ctrl k when using nano) and paste the following in for a basic site setup (change the server_name for your server name/ip. Change listen to a port you want this to listen on. I’m using the default port 80).

1
2
3
4
5
6
7
8
9
10
11
12
server {
        listen 80 default_server;
        listen [::]:80 default_server;
        
        server_name homer.example.com;

# Path to the root of your installation
        root /var/www/html/;

        access_log /var/log/nginx/homer.access;
        error_log /var/log/nginx/homer.error;
}

Test the Nginx config:

1
sudo nginx -t

If the above comes back successfully, restart nginx service.

1
sudo systemctl reload nginx

Browse to the site mentinoed in the config file, eg http://homer.example.com and you should get the default dashboard.

Homer Default Dashboard

Now that it’s all installed, you can edit the config.yml file found here: /var/www/html/assets/config.yml

For more information on configuration and settings, please go here: Github - Homer Dashbaord

Enjoy

This post is licensed under CC BY 4.0 by the author.