From 4c12ae5ea3bc289752a903252c6d89645a7bf1af Mon Sep 17 00:00:00 2001 From: NBatDB <141807851+NBatDB@users.noreply.github.com> Date: Tue, 3 Dec 2024 11:02:16 +0000 Subject: [PATCH] add opts for ip6tables --- documentation/docker_service.md | 1 + libraries/helpers_service.rb | 1 + resources/partial/_service_base.rb | 1 + 3 files changed, 3 insertions(+) diff --git a/documentation/docker_service.md b/documentation/docker_service.md index a2ecc336b..b9fe33904 100644 --- a/documentation/docker_service.md +++ b/documentation/docker_service.md @@ -62,6 +62,7 @@ The `docker_service` resource property list mostly corresponds to the options fo - `ip_masq` - Enable IP masquerading - `ip` - Default IP when binding container ports - `iptables` - Enable addition of iptables rules +- `ip6tables` - Enable addition of ip6tables rules - `ipv4_forward` - Enable net.ipv4.ip_forward - `ipv6_forward` - Enable net.ipv6.ip_forward - `ipv6` - Enable IPv6 networking diff --git a/libraries/helpers_service.rb b/libraries/helpers_service.rb index 2aa00e961..f929308f9 100644 --- a/libraries/helpers_service.rb +++ b/libraries/helpers_service.rb @@ -225,6 +225,7 @@ def docker_daemon_opts opts << "--ip-forward=#{ip_forward}" unless ip_forward.nil? opts << "--ip-masq=#{ip_masq}" unless ip_masq.nil? opts << "--iptables=#{iptables}" unless iptables.nil? + opts << "--ip6tables=#{ip6tables}" unless ip6tables.nil? opts << "--ipv6=#{ipv6}" unless ipv6.nil? opts << "--log-level=#{log_level}" if log_level labels.each { |l| opts << "--label=#{l}" } if labels diff --git a/resources/partial/_service_base.rb b/resources/partial/_service_base.rb index 77b29c3d8..afa708504 100644 --- a/resources/partial/_service_base.rb +++ b/resources/partial/_service_base.rb @@ -38,6 +38,7 @@ property :ipv6_forward, [true, false], default: true property :ip_masq, [true, false] property :iptables, [true, false] +property :ip6tables, [true, false] property :ipv6, [true, false] property :default_ip_address_pool, String property :log_level, %w(debug info warn error fatal)