Repository navigation
Description
I am having some permission issues with the shopping list which I am unable to fix. Below a screenshot from the terminal in Truenas.
The recipes are using my truenas uid and gid. But the shoppinglist doesn't use the proper uid. GID of shoppinglist is the same as my truenas gid.
![]()
My docker compose looks like this:
services:
cookcli:
image: ghcr.io/cooklang/cookcli:latest
user: "1000:1000"
ports:
- "9080:9080"
volumes:
- /mnt/tn_media/recipes:/recipes
restart: unless-stoppedthe /mnt/tn_media/recipes is a mounted folder. This is a storage location on my truenas server.
The mount is configured like this:
//xxx.xxx.x.x/media/recipes /mnt/tn_media/recipes cifs credentials=/xxx/xxxx/xxxxxxxx/.xxxxxxxxx,uid=1000,gid=1000,file_mode=0664,dir_mode=0775,noperm 0 0
On the docker host the userid is 1000 and the groupid is 1000. That works perfect for the recipes and the rest of my cookcli setup.
I can add recipes to the shoppinglist when using the webserver but the shppinglist doesn't sync to my iPhone. My recipes do sync.
.shopping-checked sync error:
[2026-10-20 08:59:15] ERROR IoError { path: ".shopping-checked", source: Os { code: 13, kind: PermissionDenied, message: "Permission denied" } }
[2026-10-20 08:59:15] WARN Sync failed: Unknown("Check download failed: IO error in file .shopping-checked: Permission denied (os error 13)")
[2026-10-20 08:59:15] ERROR Sync failed: Sync failed: Unknown("Check download failed: IO error in file .shopping-checked: Permission denied (os error 13)")
[2026-10-20 08:59:15] WARN Sync failed (attempt 5/5), retrying in 80s: Sync failed: Unknown("Check download failed: IO error in file .shopping-checked: Permission denied (os error 13)")
.shopping-list sync error:
[2026-11-01 15:38:28] ERROR IoError { path: ".shopping-list", source: Os { code: 13, kind: PermissionDenied, message: "Permission denied" } }
[2026-11-01 15:38:28] WARN Sync failed: Unknown("Check download failed: IO error in file .shopping-list: Permission denied (os error 13)")
[2026-11-01 15:38:28] ERROR Sync failed: Sync failed: Unknown("Check download failed: IO error in file .shopping-list: Permission denied (os error 13)")
[2026-11-01 15:38:28] WARN Sync failed (attempt 4/5), retrying in 40s: Sync failed: Unknown("Check download failed: IO error in file .shopping-list: Permission denied (os error 13)")
When i use iOS to add a recipe to the shoppinglist and let it sync with my webserver the uid doesn't change. But the webserver does change it to docker. Did I made a mistake in my configuration or is it a bug?
Activity
fix(server): keep a file's owner when the server rewrites it (#814)
fix: empty the checked log on Clear instead of removing it (#814)
dubadub commentedon Nov 2, 2026
Thanks for the detailed report. Your configuration is fine; this was a bug.
Whenever the web server changed the shopping list, it wrote a new file and renamed it over the old one. On an SMB share the TrueNAS server gives a new file to the account the share is mounted with,
dockerhere. Theuid=1000,gid=1000mount options only change the owner your Docker host shows, not the real one. The sync then can't write the file it no longer owns, so it fails withPermission denied. Recipes kept their owner because sync writes them in place.#819 fixes this. When a file is on an SMB/CIFS or NFS share, or a rename would change its owner, CookCLI now writes through the existing file, so it keeps its owner and permissions. The same goes for
pantry.conf,aisle.conf, recipes saved in the editor and pictures. Clearing the shopping list now empties.shopping-checkedinstead of deleting it.Two things on your side:
.shopping-listand.shopping-checkedin the recipes folder back to your user (or just delete them and add the recipes again).inherit owner = yesto the share's auxiliary parameters, so new files belong to the folder's owner;docker;docker) write access, so the owner stops mattering.Once #819 is released and the share is set up like this, the shopping list should sync again. Let us know if it doesn't.
Generated by Claude Code
jonskoglund commentedon Nov 2, 2026
Will wait for next release and report if I find any errors.
fix: keep the shopping list's owner when rewriting it (cooklang#814)