[Bug]: Unable to use NFS share due to chmod in Dockerfile #1882

Closed
opened 2026-02-28 19:57:15 -06:00 by GiteaMirror · 2 comments
Owner

Originally created by @Dhs92 on GitHub (Feb 21, 2025).

Verified issue does not already exist?

  • I have searched and found no existing issue

What happened?

Creating a docker container using the NFS driver results in the following error: Failed to deploy a stack: compose up operation failed: Error response from daemon: failed to chmod on /var/lib/docker/volumes/finance/_data: chmod /var/lib/docker/volumes/finance/_data: operation not permitted

docker-compose.yml

services:
  actual:
    image: actualbudget/actual-server:latest
    container_name: actual
    labels:
      - traefik.enable=true
      - traefik.http.routers.actual.rule=Host(`[[REDACTED]]`)
      - traefik.http.routers.actual.tls.certresolver=letsencrypt
      - traefik.http.routers.actual.entrypoints=websecure
      - traefik.http.services.actual.loadbalancer.server.port=5006
      - traefik.docker.network=traefik_proxy
    volumes:
      - finance:/data
    networks:
      - default
      - traefik_proxy
    environment:
      - ACTUAL_TRUSTED_PROXIES=172.21.0.0/16
    healthcheck:
      # Enable health check for the instance
      test: ['CMD-SHELL', 'node src/scripts/health-check.js']
      interval: 60s
      timeout: 10s
      retries: 3
      start_period: 20s
    restart: unless-stopped

networks:
  default:
  traefik_proxy:
    name: traefik_proxy
    external: true

volumes:
  finance:
    external: true

Even when creating a user on the host with the UID 1001 I get the same error.

Looks like it's possibly due to this inside of sync-server.Dockerfile:

RUN mkdir /data && chown -R ${USERNAME}:${USERNAME} /data

How can we reproduce the issue?

Create a docker container using a volume that uses the NFS driver

Where are you hosting Actual?

Docker

What browsers are you seeing the problem on?

Other

Operating System

Linux

Originally created by @Dhs92 on GitHub (Feb 21, 2025). ### Verified issue does not already exist? - [x] I have searched and found no existing issue ### What happened? Creating a docker container using the NFS driver results in the following error: `Failed to deploy a stack: compose up operation failed: Error response from daemon: failed to chmod on /var/lib/docker/volumes/finance/_data: chmod /var/lib/docker/volumes/finance/_data: operation not permitted` docker-compose.yml ```yaml services: actual: image: actualbudget/actual-server:latest container_name: actual labels: - traefik.enable=true - traefik.http.routers.actual.rule=Host(`[[REDACTED]]`) - traefik.http.routers.actual.tls.certresolver=letsencrypt - traefik.http.routers.actual.entrypoints=websecure - traefik.http.services.actual.loadbalancer.server.port=5006 - traefik.docker.network=traefik_proxy volumes: - finance:/data networks: - default - traefik_proxy environment: - ACTUAL_TRUSTED_PROXIES=172.21.0.0/16 healthcheck: # Enable health check for the instance test: ['CMD-SHELL', 'node src/scripts/health-check.js'] interval: 60s timeout: 10s retries: 3 start_period: 20s restart: unless-stopped networks: default: traefik_proxy: name: traefik_proxy external: true volumes: finance: external: true ``` Even when creating a user on the host with the UID 1001 I get the same error. Looks like it's possibly due to this inside of sync-server.Dockerfile: `RUN mkdir /data && chown -R ${USERNAME}:${USERNAME} /data` ### How can we reproduce the issue? Create a docker container using a volume that uses the NFS driver ### Where are you hosting Actual? Docker ### What browsers are you seeing the problem on? Other ### Operating System Linux
GiteaMirror added the bug label 2026-02-28 19:57:15 -06:00
Author
Owner

@youngcw commented on GitHub (Feb 27, 2025):

NFS and sqlite don't play well so you should try to use a different file share than NFS. It would be better to use some sort of synced folder vs a shared folder.

@youngcw commented on GitHub (Feb 27, 2025): NFS and sqlite don't play well so you should try to use a different file share than NFS. It would be better to use some sort of synced folder vs a shared folder.
Author
Owner

@Dhs92 commented on GitHub (Feb 27, 2025):

Ah yeah, that's fair. I'll just add a bind mount to the jail I'm running docker in the, thanks!

@Dhs92 commented on GitHub (Feb 27, 2025): Ah yeah, that's fair. I'll just add a bind mount to the jail I'm running docker in the, thanks!
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/actual#1882