Docker Community Forums

Share and learn in the Docker community.

How to setup docker0 in promiscuous mode at start up


(Wellysiauw) #1

Hello everyone, I just recently started to learn docker by using EC2 instance.
one part of my exploration is to setup docker0 interface to run in promiscuous mode.

I have no problem to get this enabled using: ip link set docker0 promisc on
however I cannot make this changes permanent after reboot.

I tried a few things:

  1. add extra line under start() method in /etc/rc.d/init.d/docker
  2. add extra check under /sbin/ifup-local to check when docker0 enabled

on both attempt, when the script executed, docker0 interface is not yet available.
this lead me wondering:

  1. When exactly docker0 interface was enabled ?
  2. What is the best way to setup docker0 interface in promiscuous mode permanently ?

additional info: all my test is done via Amazon linux AMI.