Search code examples
dockerdockerfilebgp

Specify "privileged" container mode in dockerfile?


I am a little new to Docker technology, however, I would like to deploy a couple of BGP BIRD containers throughout my infrastructure. I would like to automate container creation with Dockerfile builds, however, I can not run BIRD in docker without giving the container "privileged" mode. There doesn't appear to be a Dockerfile version for getting "privileged" mode. Are there workarounds or perhaps I am missing the point?


Solution

  • You can't give privileged mode in Dockerfile. You can only run by --privileged when start docker by command line. There is one other way, that you can try start you docker container via Docker API

    And set request param for auto run with privileged mode.

    As I know, normal case you need to run docker in privileged mode is you wanna run docker in docker. What BIRD container is ?