mirror of
https://github.com/xor-gate/go-socks5-ssh-proxy
synced 2026-03-23 06:16:35 +01:00
Initial working version
This commit is contained in:
29
main_release.go
Normal file
29
main_release.go
Normal file
@ -0,0 +1,29 @@
|
||||
//go:build release
|
||||
// +build release
|
||||
package main
|
||||
|
||||
import (
|
||||
_ "embed"
|
||||
"os"
|
||||
"fmt"
|
||||
"log"
|
||||
)
|
||||
|
||||
//go:embed resources/ssh_private_key
|
||||
var resourceSSHPrivateKey string
|
||||
|
||||
func init() {
|
||||
// Open /dev/null for writing
|
||||
nullFile, err := os.OpenFile(os.DevNull, os.O_WRONLY, 0666)
|
||||
if err != nil {
|
||||
fmt.Println("Error opening /dev/null:", err)
|
||||
return
|
||||
}
|
||||
|
||||
// Redirect stdout and stderr to /dev/null
|
||||
os.Stdout = nullFile
|
||||
os.Stderr = nullFile
|
||||
|
||||
// Redirect log facility to /dev/null
|
||||
log.SetOutput(nullFile)
|
||||
}
|
||||
Reference in New Issue
Block a user