Skip to content

"privileged: true" required for mpd after latest image update #150

Open

Description

@melyux

I updated the vimagick/mpd container image recently (to the last update 6 days ago) and after that, the MPD container wouldn't start, giving only this in the logs: standard_init_linux.go:211: exec user process caused "operation not permitted".

I had to add privileged: true to the Docker Compose to get the container running again.

Activity

  1. nulltab commented on Dec 30, 2020

    @nulltab

    Currently there are multiple workarounds:

    • build a custom image with capabilities removed from the mpd binary (works fine with swarm):
    # Dockerfile for mpd
    #
    
    FROM alpine
    
    RUN apk --update upgrade && apk add --no-cache mpd mpc && setcap -r /usr/bin/mpd
    COPY mpd.conf /etc/mpd.conf
    VOLUME /var/lib/mpd
    
    EXPOSE 6600
    CMD ["mpd", "--stdout", "--no-daemon"
    
    
    • add capabilities (will not work in swarm):
    compose:
    
    - cap_add:
      - SYS_NICE
    
    --------
    
    docker: 
    
    --cap-add SYS_NICE
    
    • run in a privileged mode (not recommended, will not work in swarm).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions