79499199

Date: 2025-03-10 21:36:24
Score: 0.5
Natty:
Report link

BusyBox uses sh -c differently, and tini is trying to execute the whole command as a binary rather than passing it to the shell.

Modify command like this:

command: ["/bin/sh", "-c", "mkdir -p /usr/local/unbound/cachedb.d && chown -R 1000:1000 /usr/local/unbound/cachedb.d/"]
services:
  unbound-db-socket:
    image: busybox:latest
    container_name: unbound-db-socket
    init: true
    tty: true
    command: ["/bin/sh", "-c", "mkdir -p /usr/local/unbound/cachedb.d && chown -R 1000:1000 /usr/local/unbound/cachedb.d/"]
    volumes:
       - "cachedb.d:/usr/local/unbound/cachedb.d/"

volumes:
  cachedb.d:

networks:
  bridge:
Reasons:
  • Probably link only (1):
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: Farkhod Abdukodirov