osixia / docker-keepalived

Keepalived container image 🐳🌴
MIT License
402 stars 146 forks source link

cant not use link config to config keepalived #17

Closed Trisia closed 5 years ago

Trisia commented 6 years ago

I follow the section "Use your own Keepalived config" run this command docker run --cap-add=NET_ADMIN --net=host -v /home/ke.conf:/container/service/keepalived/assets/keepalived.conf -it osixia/keepalived:1.4.4 --loglevel debug

/home/ke.conf looks like this

global_defs {
  default_interface eth0
}

vrrp_instance VI_1 {
  interface eth0

  track_interface {
    eth0
  }

  state BACKUP
  virtual_router_id 51
  priority 150

  virtual_ipaddress {
    172.17.64.111
  }

  authentication {
    auth_type PASS
    auth_pass d0cker
  }

  notify "/container/service/keepalived/assets/notify.sh"
}

Through the BUG mode I got these info

sed: can't move '/container/service/keepalived/assets/keepalived.confJBHFPJ' to '/container/service/keepalived/assets/keepalived.conf': Resource busy
jeffdesc commented 6 years ago

Issue resolved with https://github.com/osixia/docker-keepalived#fix-docker-mounted-file-problems