Can't install Homarr on Docker
I use Portainer for docker and copy pasted the docker compose and changed the host volume locations and got the error in the text file.
This is what im using for docker compose
version: '3'
#---------------------------------------------------------------------#
Homarr - A simple, yet powerful dashboard for your server. #
#---------------------------------------------------------------------#
services:
homarr:
container_name: homarr
image: ghcr.io/ajnart/homarr:latest
restart: unless-stopped
volumes:
- /droidlab/docker/homarr/configs:/app/data/configs
- /droidlab/docker/homarr/icons:/app/public/icons
- /droidlab/docker/homarr/data:/data
ports:
- '7575:7575'
36 Replies
Key error from log:
failed to register layer: ApplyLayer exit status 1 stdout: stderr: unlinkat /app/node_modules/resolve-alpn: invalid argument
Invalid argument for '''unlinkat''' leads me to believe a permissions issue, or a file path issue.
I really need to learn file permissons in linux, usually I just do 777 but its bad practice, what would you recommend?
I unfortunately don't know much about portianer or how it functions
Ok, ill install via docker cli and see if anything changes
Does the directory exist already? If so who owns it? I wonder if you can change ownership to the user the docker container would use and then retry
It’s a location/volume issue for sure. Can you elaborate on why you want to the data directories moved?
version: '3'
#---------------------------------------------------------------------#
Homarr - A simple, yet powerful dashboard for your server. #
#---------------------------------------------------------------------#
services:
homarr:
container_name: homarr
image: ghcr.io/ajnart/homarr:latest
restart: unless-stopped
volumes:
- /var/run/docker.sock:/var/run/docker.sock # Optional, only if you want docker integration
- ./homarr/configs:/app/data/configs
- ./homarr/icons:/app/public/icons
- ./homarr/data:/data
ports:
- '7575:7575'
It does and it should be the second user i created on the vm, i created the folder with that user
I run a bunch of docker containers in separate proxmox containers so i use the same folder name across all of them to find data easier
Ok, well I have no experience with that. It looks like a volume issue though
i tried installing specifically version 0.13.4 and deleted all folders before hand to just let docker create them and that works just fine, any version above that does not work on any of my vms now
I can confirm when using custom locations, 0.13.4 is the latest version that works.
when using default locations, it works on 'latest' and all other versions
Hi @Spink , can you open a new post? The default commands in our documentation should work...
Yes the defaults work. But not when you modify the location of the three paths.
Can you make a new post? Pretty sure you configure it incorrectly
But it's the same issue as op here?
Can you post your run or compose here then?
version: '3'
#---------------------------------------------------------------------#
# Homarr - A simple, yet powerful dashboard for your server. #
#---------------------------------------------------------------------#
services:
homarr:
container_name: homarr
image: ghcr.io/ajnart/homarr:latest
restart: unless-stopped
volumes:
- /var/run/docker.sock:/var/run/docker.sock # Optional, only if you want docker integration
- /mnt/Docker/homarr:/app/data/configs
- /mnt/Docker/homarr:/app/public/icons
- /mnt/Docker/homarr:/data
ports:
- '7575:7575'
Ok, so your problem is completely unrelated to OPs. And you said that this only happens when you configure a different path?
@Meierschlumpf this is another case with failing migrations. Can you take note of it? When we collect enough data, we might be able to rule out until we find the cause.
this is a brand new install though
Ok. So? We still apply migrations...
ok, just clarifying.
No problem. It's unrelated to OP (at least from my point of view). Let's wait for Meier.
Many thanks, should I make a new post?
Since you already posted the log here, let's wait for Meier. We most likely have an issue on GitHub.
Hi, you are trying to use the same folder for all your mounts, the docs clearly says not to do that
Try using this instead for volumes:
Try to change the db mount path. Not sure why, but your db is locked and seemsto be accessed from another process
yeah I tried this later that evening with the same result.
volumes: - /var/run/docker.sock:/var/run/docker.sock # Optional, only if you want docker integration - /mnt/Docker/homarrr/configs:/app/data/configs - /mnt/Docker/homarrr/icons:/app/public/icons - /mnt/Docker/homarrr/data:/dataand I also changed the path (added an extra r to homarr) to test the DB lock I thought perhaps the DB lock was from the NAS recyclingbin/snapshots but it didn't change anything. permissions look ok for that folder. (it's able to create folders and config files.) db.sqlite file in the data folder is zero bytes.
Delete the database and restart? It sometimes work
tried that. it creates a db.sqlite.journal file and db.sqlite and then the journal disappears a few seconds later
It looks like the database is not liking the folder, do as Meierschlumpf said and try changing the mount path of just the database
yes, no issues here with data set to it's default. ./homarr/data
Exporting hostname...
Migrating database...
yarn run v1.22.19
$ ts-node ./migrate.ts
Done in 1.74s.
Starting production server...
Listening on port 7575 url: http://2f3c8f123988:7575
ℹ Instance is using a database on the file system. Checking if file '/data/db.sqlite' is writable...
ℹ Database is writeable
but not sure why it's not working when that's set to somewhere else.I'll hand that back to @Meierschlumpf then
What are u using for running those containers?
Maybe I can setup it myself and check more directly
portainer community 2.19.2
Sadly I was not able to reproduce your issue, I deployed homarr with Portainer on my Rasperry Pi without any issues
I have the same setup, running Portainer 2.19.4 on an Ubuntu host and using the exact same compose file as you apart from I have not seperated out the volumes you have under integration.
I just have
volumes:
- /var/run/docker.sock:/var/run/docker.sock # Optional, only if you want docker integration
- /portainer/homarr/configs:/app/data/configs
- /portainer/homarr/icons:/app/public/icons
- /portainer/homarr/data:/data
I have changed the mount just because I like to have all my Portainer data under a single top level folder (Portainer) then sub folders for each container