Skip to content

Commit c7e51c6

Browse files
committed
[openvpn] Added "pull" option for clients
1 parent b486c4d commit c7e51c6

File tree

4 files changed

+14
-0
lines changed

4 files changed

+14
-0
lines changed

Diff for: docs/source/backends/openvpn.rst

+2
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,8 @@ Required properties:
182182
+--------------------------+---------+--------------+-------------------------------------------------------------+
183183
| ``tls_client`` | boolean | ``True`` | |
184184
+--------------------------+---------+--------------+-------------------------------------------------------------+
185+
| ``pull`` | boolean | ``True`` | |
186+
+--------------------------+---------+--------------+-------------------------------------------------------------+
185187
| ``auth_user_pass`` | string | | any non whitespace character |
186188
+--------------------------+---------+--------------+-------------------------------------------------------------+
187189

Diff for: docs/source/backends/openwisp.rst

+1
Original file line numberDiff line numberDiff line change
@@ -232,6 +232,7 @@ The following example shows a full working *configuration dictionary* for the
232232
"key": "/tmp/owispmanager/openvpn/x509/l2vpn_client_2693.pem",
233233
"ns_cert_type": "server",
234234
"mode": "p2p",
235+
"pull": True,
235236
"enabled": True,
236237
"comp_lzo": "yes",
237238
"down": "/tmp/owispmanager/openvpn/vpn_2693_script_down.sh",

Diff for: netjsonconfig/backends/openvpn/schema.py

+9
Original file line numberDiff line numberDiff line change
@@ -428,6 +428,15 @@
428428
"format": "checkbox",
429429
"propertyOrder": 9,
430430
},
431+
"pull": {
432+
"title": "pull",
433+
"description": "accept options pushed by the server, provided they are "
434+
"part of the legal set of pushable options",
435+
"type": "boolean",
436+
"default": True,
437+
"format": "checkbox",
438+
"propertyOrder": 10,
439+
},
431440
"ns_cert_type": {
432441
"description": "Require that peer certificate was signed with an explicit "
433442
"nsCertType designation of \"server\"",

Diff for: tests/openvpn/test_backend.py

+2
Original file line numberDiff line numberDiff line change
@@ -129,6 +129,7 @@ def test_client_mode(self):
129129
"persist_tun": True,
130130
"port": 1195,
131131
"proto": "tcp-client",
132+
"pull": True,
132133
"remote": [
133134
{
134135
"host": "vpn1.test.com",
@@ -177,6 +178,7 @@ def test_client_mode(self):
177178
persist-tun
178179
port 1195
179180
proto tcp-client
181+
pull
180182
remote vpn1.test.com 1194
181183
remote vpn2.test.com 1195
182184
resolv-retry

0 commit comments

Comments
 (0)