Creating a Heimdall service using docker-compose can be done with the below basic docker-compose.yml -
--- version: "2" services: heimdall: image: linuxserver/heimdall container_name: heimdall environment: - PUID=65522 - PGID=65522 - TZ=Europe/London volumes: - ./config:/config ports: - 8080:80 restart: unless-stopped
Further customization of the default user and other users can be done within the app itself. Once logged in, set a password for the admin and decide if you want public view on or off. Its important to note that the Heimdall dashboards are user-specific, and act according to their users settings.
Before starting your service, you should take note of the port that your local host will pass to this container. (
local:container). Also be sure to mount the volumes you wish to further configure / modify, so you will have easy access to them. To do this, just add a volume to the list above -
volumes: - ./config:/config - /etc/docker-heimdall/:/config
The above added volume will also mount the
/config directory on the container to the
/etc/docker-heimdall/ directory on our local host. This feature can be used to store directories in such a way that will make backing up our service and its files much easier.
Stopping / Starting Heimdall
Create a directory to store your Heimdall configuration files and / or mounted volumes, and within it insert a
docker-compose.yml file with the above contents and run
docker-compose up -d. This will start the services we defined, mount the volumes specified, along the ports we set in the
docker-compose.yml. This file can be further modified to suit the needs of your application / local server. Adding mounted volumes is a useful feature when planning your service, since these directories will be available locally they will be easy to backup and modify.
Starting defined services -
admin@host:~/heimdall$ docker-compose up -d Creating network "heimdall_default" with the default driver Creating heimdall ... done admin@host:~/heimdall$
Stop and remove created containers / networks -
admin@host:~/heimdall$ docker-compose down Stopping heimdall ... done Removing heimdall ... done Removing network heimdall_default admin@host:~/heimdall$