@@ -423,6 +423,8 @@ export async function multipassUnroute(
423
423
await inheritExec ( {
424
424
cmd,
425
425
stdin : { inherit : true } ,
426
+ stdout : { read : printOutLines ( ( line ) => `${ gray ( "[$ Remove-NetRoute ]" ) } ${ line } ` ) } ,
427
+ stderr : { read : printErrLines ( ( line ) => `${ gray ( "[$ Remove-NetRoute ]" ) } ${ line } ` ) } ,
426
428
} ) ;
427
429
}
428
430
@@ -433,6 +435,8 @@ export async function multipassUnroute(
433
435
`Foreach($x in (Get-DnsClientNrptRule | Where-Object {$_.Namespace -eq ".svc.${ clusterDomain } "} | foreach {$_.Name})){ Remove-DnsClientNrptRule -Name "$x" -Force }` ,
434
436
] ,
435
437
stdin : { inherit : true } ,
438
+ stdout : { read : printOutLines ( ( line ) => `${ gray ( "[$ Remove-DnsClientNrptRule ]" ) } ${ line } ` ) } ,
439
+ stderr : { read : printErrLines ( ( line ) => `${ gray ( "[$ Remove-DnsClientNrptRule ]" ) } ${ line } ` ) } ,
436
440
} ) ;
437
441
} else {
438
442
log ( "Removing routes, will require root permissions..." ) ;
@@ -441,6 +445,8 @@ export async function multipassUnroute(
441
445
await inheritExec ( {
442
446
cmd : [ "sudo" , "/sbin/route" , "delete" , "-net" , cidr , ip ] ,
443
447
stdin : { inherit : true } ,
448
+ stdout : { read : printOutLines ( ( line ) => `${ gray ( "[$ route ]" ) } ${ line } ` ) } ,
449
+ stderr : { read : printErrLines ( ( line ) => `${ gray ( "[$ route ]" ) } ${ line } ` ) } ,
444
450
} ) ;
445
451
} catch {
446
452
// Ignore
@@ -451,6 +457,8 @@ export async function multipassUnroute(
451
457
await inheritExec ( {
452
458
cmd : [ "sudo" , "rm" , "-f" , `/etc/resolver/svc.${ clusterDomain } ` ] ,
453
459
stdin : { inherit : true } ,
460
+ stdout : { read : printOutLines ( ( line ) => `${ gray ( "[$ resolver ]" ) } ${ line } ` ) } ,
461
+ stderr : { read : printErrLines ( ( line ) => `${ gray ( "[$ resolver ]" ) } ${ line } ` ) } ,
454
462
} ) ;
455
463
} catch {
456
464
// Ignore
0 commit comments