1+ # -*- coding: utf-8 -*-
2+ # vim: ft=yaml
3+ ---
14# See https://openvpn.net/index.php/open-source/documentation/howto.html#examples
25# for configuration details
36# Important: Replace all '-' in names on left side with '_'!
47
58# Defaults can be overwritten, see openvpn/map.jinja for default values
69# openvpn:
710# lookup:
8- # dh_files: ['4096'] # This creates a dh file with 4096 bits (which will take a long time).
9- # dh_files: ['2048'] # This creates a dh file with 2048 bits (which should be enough.)
10- # # Default: ['2048', '4096']
11- # # (It creates both variants.)
11+ # # This creates a dh file with 4096 bits (which will take a long time).
12+ # dh_files: ['4096']
13+ # # This creates a dh file with 2048 bits (which should be enough.)
14+ # # Default: ['2048', '4096']
15+ # # (It creates both variants.)
16+ # dh_files: ['2048']
1217#
13- # dsaparam: False # Set this to True if you want to use the -dsaparam flag in DH param generation.
14- # # See also:
15- # # https://github.com/saltstack-formulas/openvpn-formula/pull/77
16- # # https://security.stackexchange.com/questions/42415/openvpn-dhparam
18+ # # Set this to true if you want to use the -dsaparam flag in DH param generation.
19+ # # See also:
20+ # # https://github.com/saltstack-formulas/openvpn-formula/pull/77
21+ # # https://security.stackexchange.com/questions/42415/openvpn-dhparam
22+ # dsaparam: false
1723#
18- # external_repo_enabled: True # This will use the OpenVPN repository documented
19- # # at the following URL: https://community.openvpn.net/openvpn/wiki/OpenvpnSoftwareRepos
20- # # Only valid for Debian OS family
24+ # # This will use the OpenVPN repository documented
25+ # # at the following URL:
26+ # # https://community.openvpn.net/openvpn/wiki/OpenvpnSoftwareRepos
27+ # # Only valid for Debian OS family
28+ # external_repo_enabled: true
2129#
22- # external_repo_version: testing # The version to use for OpenVPN if 'external_repo_enabled' is set to 'True'
23- # # Info here: https://community.openvpn.net/openvpn/wiki/OpenvpnSoftwareRepos
24- # # Valid options: stable (default), testing, release/2.3, release/2.4
30+ # # The version to use for OpenVPN if 'external_repo_enabled' is set to 'true'
31+ # # Info here: https://community.openvpn.net/openvpn/wiki/OpenvpnSoftwareRepos
32+ # # Valid options: stable (default), testing, release/2.3, release/2.4
33+ # external_repo_version: testing
2534
26- #See also the example used in tests: test/integration/repositories/pillars.sls
35+ # See also the example used in tests: test/integration/repositories/pillars.sls
2736
2837# #
2938# OpenVPN user and group
3039#
3140# For historic reasons these are the default values:
32- #openvpn:
41+ # openvpn:
3342# lookup:
3443# user: nobody
3544# group: nobody # nogroup on Debian
@@ -43,17 +52,16 @@ openvpn:
4352 group : openvpn
4453 # When the user is not 'nobody', it will be managed by this formula.
4554 # You can suppress this by: (Default on FreeBSD)
46- manage_user: False
55+ manage_user : false
4756 # When the group is neither 'nobody' nor 'nogroup',
4857 # it will be managed by this formula.
4958 # You can suppress this by: (Default on FreeBSD)
50- manage_group: False
59+ manage_group : false
5160
5261 # If you want to control the openvpn services via other tools,
5362 # you want to 'disabled' it in your system. Default: running
54- #service_function: disabled
63+ # service_function: disabled
5564
56- openvpn:
5765 server :
5866 myserver1 :
5967 ca : /path/to/mycacert.pem
@@ -100,7 +108,7 @@ openvpn:
100108 # tl;dr: The bigger, the better.
101109 dh : dh4096.pem
102110 # for faster DP params generation use only ['2048'] in openvpn:lookup:dh_files
103- #dh: dh2048.pem
111+ # dh: dh2048.pem
104112 server : ' 10.8.0.0 255.255.255.0'
105113 ifconfig_pool_persist : ipp.txt
106114 server_bridge :
@@ -114,8 +122,8 @@ openvpn:
114122 client1 : |
115123 iroute 192.168.10.0 255.255.255.0
116124 learn_address :
117- client_to_client: False
118- duplicate_cn: False
125+ client_to_client : false
126+ duplicate_cn : false
119127 keepalive : ' 10 120'
120128 # `tls-auth` and `tls-crypt` are mutually exclusive
121129 # and `tls-crypt` is only valid for OpenVPN 2.4 and above.
@@ -133,6 +141,7 @@ openvpn:
133141 - AES-256-CBC
134142 auths :
135143 - SHA384
144+ # yamllint disable-line rule:line-length
136145 tls_cipher : ' DHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES256-SHA256:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES128-SHA256:DHE-RSA-CAMELLIA256-SHA:DHE-RSA-AES256-SHA:DHE-RSA-CAMELLIA128-SHA:DHE-RSA-AES128-SHA:CAMELLIA256-SHA:AES256-SHA:CAMELLIA128-SHA:AES128-SHA'
137146 comp_lzo :
138147 max_clients : 100
@@ -162,9 +171,9 @@ openvpn:
162171 ifconfig : ' 10.8.0.1 10.8.0.2'
163172 secret : /path/to/mysecret.key
164173 # or
165- #secret: /path/to/mysecret.key 0
174+ # secret: /path/to/mysecret.key 0
166175 # or
167- #secret: # use this form for paths with spaces
176+ # secret: # use this form for paths with spaces
168177 # - /path/to/mysecret.key
169178 # - 0
170179 secret_content : |
@@ -211,13 +220,11 @@ openvpn:
211220 http_proxy_retry :
212221 http_proxy : ' proxy-server proxy-port'
213222 mute_replay_warnings :
214- {% if grains['os_family'] == 'Windows' %}
215- dev_node: ovpn-myclient2
216- # Take care with the quoting for Windows paths with spaces
217- ca: '"C:\\Program Files\\OpenVPN\\config\\mycacert.pem"'
218- {% else %}
219223 ca : /path/to/mycacert.pem
220- {% endif %}
224+ # The following two commented options are examples for Windows
225+ # dev_node: ovpn-myclient2
226+ # Take care with the quoting for Windows paths with spaces
227+ # ca: '"C:\\Program Files\\OpenVPN\\config\\mycacert.pem"'
221228 ca_content : |
222229 -----BEGIN CERTIFICATE-----
223230 ...
@@ -236,7 +243,7 @@ openvpn:
236243 askpass_content : |
237244 p4ssw0rd
238245 ns_cert_type : server
239- #tls_auth: /path/to/tls.key 0
246+ # tls_auth: /path/to/tls.key 0
240247 # or:
241248 tls_auth : # use this form for paths with spaces
242249 - /path/to/tls.key
@@ -250,16 +257,17 @@ openvpn:
250257 - AES-256-CBC
251258 auths :
252259 - SHA384
260+ # yamllint disable-line rule:line-length
253261 tls_cipher : ' DHE-RSA-AES256-GCM-SHA384:DHE-RSA-AES256-SHA256:DHE-RSA-AES128-GCM-SHA256:DHE-RSA-AES128-SHA256:DHE-RSA-CAMELLIA256-SHA:DHE-RSA-AES256-SHA:DHE-RSA-CAMELLIA128-SHA:DHE-RSA-AES128-SHA:CAMELLIA256-SHA:AES256-SHA:CAMELLIA128-SHA:AES128-SHA'
254262 remote_cert_tls : server
255263 comp_lzo :
256264 verb : 3
257265 mute : 20
258266 up : /usr/local/bin/tunnel_up.sh
259267 down : /usr/local/bin/tunnel_down.sh
260- up_delay: True
261- down_pre: True
262- up_restart: True
268+ up_delay : true
269+ down_pre : true
270+ up_restart : true
263271 _append :
264272 - script-security 2
265273 - up 'echo up'
@@ -283,12 +291,12 @@ openvpn:
283291 route :
284292 - " 8.8.8.8 255.255.255.255 net_gateway"
285293 myclient3 :
286- pull: False
294+ pull : false
287295 # from the man page:
288296 # This option must be used on a client which is connecting to a
289297 # multi-client server. It indicates to OpenVPN that it should accept
290298 # options pushed by the server, provided they are part of the legal
291- # set of pushable options
299+ # set of pushable options
292300
293301 ifconfig_pool_persist :
294302 ipp.txt :
@@ -301,7 +309,7 @@ openvpn:
301309
302310 # #
303311 # Use latest OpenVPN packages (default: false)
304- use_latest: False
312+ use_latest : false
305313
306314 # Managing clients which use NetworkManager
307315 # (Intentionally does not handle certificate/key distribution!)
0 commit comments