-
Notifications
You must be signed in to change notification settings - Fork 152
Open
Description
Everytime i update the linked keepalived config on the host, i need to stop and remove the container, then create it again.
A container restart, recreate or edit(re-deploy through Portainer) does not copy the changed config file to the local folder.
I now do this:
sudo docker container stop keepalived
sudo docker container rm keepalived
sudo docker-compose up -d
And to test if the new config is loaded
sudo docker exec keepalived cat /usr/local/etc/keepalived/keepalived.conf
It should copy and use the new config file on every (re)start.
I use the following docker-compose config:
keepalived:
container_name: keepalived
image: osixia/keepalived:2.0.20
network_mode: host
pid: host
volumes:
- /srv/docker/keepalived/keepalived.conf:/container/service/keepalived/assets/keepalived.conf
restart: always
cap_add:
- NET_ADMIN
- NET_BROADCAST
- NET_RAW
command: [--copy-service, --loglevel, debug]
environment:
KEEPALIVED_COMMAND_LINE_ARGUMENTS: >-
--log-detail
--log-console
adietrich-ussignal and NeoPlayer13
Metadata
Metadata
Assignees
Labels
No labels