File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -53,9 +53,15 @@ impl WireguardInterfaceApi for WGApi<Kernel> {
5353
5454        debug ! ( "WireGuard configuration file {file_name} created in {file_path}. Preparing configuration..." ) ; 
5555
56+         let  address = config
57+             . addresses 
58+             . iter ( ) 
59+             . map ( |addr| addr. to_string ( ) ) 
60+             . collect :: < Vec < String > > ( ) 
61+             . join ( "," ) ; 
5662        let  mut  wireguard_configuration = format ! ( 
57-             "[Interface]\n PrivateKey = {}\n Address = {}\n " , 
58-             config. prvkey,  config . address 
63+             "[Interface]\n PrivateKey = {}\n Address = {address }\n " , 
64+             config. prvkey
5965        ) ; 
6066
6167        if  !dns. is_empty ( )  { 
@@ -315,7 +321,7 @@ impl WireguardInterfaceApi for WGApi<Kernel> {
315321    fn  configure_dns ( 
316322        & self , 
317323        dns :  & [ IpAddr ] , 
318-         search_domains :  & [ & str ] , 
324+         _search_domains :  & [ & str ] , 
319325    )  -> Result < ( ) ,  WireguardInterfaceError >  { 
320326        debug ! ( 
321327            "Configuring DNS for interface {}, using address: {dns:?}" , 
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments