Reset tpl with autoconf
This commit is contained in:
parent
1139246888
commit
224b3e6026
@ -205,9 +205,9 @@ dispatch_put('/settings', function() {
|
|||||||
ynh_setting_set('ip6_addr', $ip6_addr);
|
ynh_setting_set('ip6_addr', $ip6_addr);
|
||||||
|
|
||||||
if($autoconf) {
|
if($autoconf) {
|
||||||
if(!empty($config['openvpn_add'])) {
|
copy('/etc/openvpn/client.conf.tpl.restore', '/etc/openvpn/client.conf.tpl');
|
||||||
copy('/etc/openvpn/client.conf.tpl.restore', '/etc/openvpn/client.conf.tpl');
|
|
||||||
|
|
||||||
|
if(!empty($config['openvpn_add'])) {
|
||||||
$raw_openvpn = file_get_contents('/etc/openvpn/client.conf.tpl');
|
$raw_openvpn = file_get_contents('/etc/openvpn/client.conf.tpl');
|
||||||
$raw_openvpn .= "\n# Custom\n".$config['openvpn_add'];
|
$raw_openvpn .= "\n# Custom\n".$config['openvpn_add'];
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user