diff options
author | Viacheslav Hletenko <v.gletenko@vyos.io> | 2023-09-15 12:47:00 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-09-15 12:47:00 +0300 |
commit | 27ad9f5ba6437d66178450b37c7a5bf79bc3d67a (patch) | |
tree | 439fbd80bbd01fc9e1f9d68df812fe7182e499b9 /data/templates | |
parent | 87af544259734821648dba71cd9e9b47ef833aa2 (diff) | |
parent | 1c49d3ef8855577fb5bfab014ecfbabb10f25532 (diff) | |
download | vyos-1x-27ad9f5ba6437d66178450b37c7a5bf79bc3d67a.tar.gz vyos-1x-27ad9f5ba6437d66178450b37c7a5bf79bc3d67a.zip |
Merge pull request #2185 from sever-sever/T5261-new
T5261: Add AWS load-balancing tunnel handler
Diffstat (limited to 'data/templates')
-rw-r--r-- | data/templates/aws/override_aws_gwlbtun.conf.j2 | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/data/templates/aws/override_aws_gwlbtun.conf.j2 b/data/templates/aws/override_aws_gwlbtun.conf.j2 new file mode 100644 index 000000000..4c566d852 --- /dev/null +++ b/data/templates/aws/override_aws_gwlbtun.conf.j2 @@ -0,0 +1,36 @@ +{% set args = [] %} +{% if script.on_create is vyos_defined %} +{% set _ = args.append("-c " + script.on_create) %} +{% endif %} +{% if script.on_destroy is vyos_defined %} +{% set _ = args.append("-r " + script.on_destroy) %} +{% endif %} + +{% if status.port is vyos_defined %} +{% set _ = args.append("-p " + status.port) %} +{% endif %} + +{% if threads.tunnel is vyos_defined %} +{% set _ = args.append("--tunthreads " + threads.tunnel) %} +{% endif %} +{% if threads.tunnel_affinity is vyos_defined %} +{% set _ = args.append("--tunaffinity " + threads.tunnel_affinity) %} +{% endif %} + +{% if threads.udp is vyos_defined %} +{% set _ = args.append("--udpthreads " + threads.udp) %} +{% endif %} +{% if threads.udp_affinity is vyos_defined %} +{% set _ = args.append("--udpaffinity " + threads.udp_affinity) %} +{% endif %} + +[Unit] +StartLimitIntervalSec=0 +After=vyos-router.service + +[Service] +EnvironmentFile= +ExecStart=/usr/bin/gwlbtun {{ args | join(' ') }} +CapabilityBoundingSet=CAP_NET_ADMIN +Restart=always +RestartSec=10 |