mirror of
				https://github.com/Ysurac/openmptcprouter-feeds.git
				synced 2025-03-09 15:40:03 +00:00 
			
		
		
		
	Start glorytun-udp when refresh of config
This commit is contained in:
		
							parent
							
								
									c968476130
								
							
						
					
					
						commit
						feeb9059c4
					
				
					 2 changed files with 3 additions and 5 deletions
				
			
		| 
						 | 
				
			
			@ -128,11 +128,8 @@ function updown.write(self, section, value)
 | 
			
		|||
		end
 | 
			
		||||
	else
 | 
			
		||||
		local type = proto.cfgvalue(self,section)
 | 
			
		||||
		if type == 'udp' then
 | 
			
		||||
			luci.sys.call("/etc/init.d/glorytun-udp start %s" % section)
 | 
			
		||||
		else
 | 
			
		||||
			luci.sys.call("/etc/init.d/glorytun start %s" % section)
 | 
			
		||||
		end
 | 
			
		||||
		luci.sys.call("/etc/init.d/glorytun-udp start %s" % section)
 | 
			
		||||
		luci.sys.call("/etc/init.d/glorytun start %s" % section)
 | 
			
		||||
	end
 | 
			
		||||
	luci.http.redirect( self.redirect )
 | 
			
		||||
end
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -4,6 +4,7 @@ uci -q batch <<-EOF >/dev/null
 | 
			
		|||
	delete ucitrack.@glorytun[-1]
 | 
			
		||||
	add ucitrack glorytun
 | 
			
		||||
	set ucitrack.@glorytun[-1].init=glorytun
 | 
			
		||||
	set ucitrack.@glorytun[-1].affects=glorytun-udp
 | 
			
		||||
	delete ucitrack.@glorytun-udp[-1]
 | 
			
		||||
	add ucitrack glorytun-udp
 | 
			
		||||
	set ucitrack.@glorytun-udp[-1].init=glorytun-udp
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue