docker-formula
docker-formula copied to clipboard
[FEATURE] Manage "driver" and "driver_opts" in docker.networks.install state
Is your feature request related to a problem?
No
Describe the solution you'd like
Manage "driver" and "driver_opts" in docker.networks.install state
Salt docker_network.present syntax1 :
mynet:
docker_network.present:
- driver: macvlan
- driver_opts: macvlan_mode=bridge,parent=eth0
Salt docker_network.present syntax2 :
mynet:
docker_network.present:
- driver: macvlan
- driver_opts:
- macvlan_mode=bridge
- parent=eth0
Salt docker_network.present state Docker bridge driver options
Describe alternatives you've considered
Additional context
My use case is to manage "com.docker.network.bridge.name" driver_opts in order to rename bridge name
Would adding something like this accomplish the driver request and allow additional configuration of network?
docker-network-{{ name }}-present:
docker_network.present:
- name: {{ name }}
- unless: docker network ls | grep ' {{ name }} '
{{- format_kwargs(d.networks[name]) }}