File tree Expand file tree Collapse file tree 4 files changed +11
-6
lines changed
Expand file tree Collapse file tree 4 files changed +11
-6
lines changed Original file line number Diff line number Diff line change 44 "context"
55 "flag"
66 "fmt"
7- "github.com/e2b-dev/infra/packages/orchestrator/internal/proxy"
87 "log"
98 "os"
109 "os/signal"
@@ -14,6 +13,7 @@ import (
1413 "go.opentelemetry.io/otel"
1514
1615 "github.com/e2b-dev/infra/packages/orchestrator/internal/dns"
16+ "github.com/e2b-dev/infra/packages/orchestrator/internal/proxy"
1717 "github.com/e2b-dev/infra/packages/orchestrator/internal/sandbox"
1818 "github.com/e2b-dev/infra/packages/orchestrator/internal/sandbox/nbd"
1919 "github.com/e2b-dev/infra/packages/orchestrator/internal/sandbox/network"
@@ -52,6 +52,8 @@ func main() {
5252 }()
5353
5454 dnsServer := dns .New ()
55+ proxyServer := proxy .New (3333 )
56+
5557 go func () {
5658 log .Printf ("Starting DNS server" )
5759
@@ -88,6 +90,7 @@ func main() {
8890 * buildId ,
8991 * sandboxId + "-" + strconv .Itoa (v ),
9092 dnsServer ,
93+ proxyServer ,
9194 time .Duration (* keepAlive )* time .Second ,
9295 networkPool ,
9396 templateCache ,
Original file line number Diff line number Diff line change 44 "context"
55 "flag"
66 "fmt"
7- "github.com/e2b-dev/infra/packages/orchestrator/internal/proxy"
87 "log"
98 "os"
109 "os/signal"
@@ -15,6 +14,7 @@ import (
1514 "golang.org/x/sync/errgroup"
1615
1716 "github.com/e2b-dev/infra/packages/orchestrator/internal/dns"
17+ "github.com/e2b-dev/infra/packages/orchestrator/internal/proxy"
1818 "github.com/e2b-dev/infra/packages/orchestrator/internal/sandbox"
1919 "github.com/e2b-dev/infra/packages/orchestrator/internal/sandbox/nbd"
2020 "github.com/e2b-dev/infra/packages/orchestrator/internal/sandbox/network"
@@ -52,6 +52,7 @@ func main() {
5252 cancel ()
5353 }()
5454
55+ proxyServer := proxy .New (3333 )
5556 dnsServer := dns .New ()
5657 go func () {
5758 log .Printf ("Starting DNS server" )
@@ -91,6 +92,7 @@ func main() {
9192 * buildId ,
9293 * sandboxId + "-" + strconv .Itoa (v ),
9394 dnsServer ,
95+ proxyServer ,
9496 time .Duration (* keepAlive )* time .Second ,
9597 networkPool ,
9698 templateCache ,
Original file line number Diff line number Diff line change 77 "context"
88 "errors"
99 "fmt"
10- "github.com/e2b-dev/infra/packages/orchestrator/internal/proxy"
1110 "net/http"
1211 "os"
1312 "sync/atomic"
@@ -22,6 +21,7 @@ import (
2221 "golang.org/x/sys/unix"
2322
2423 "github.com/e2b-dev/infra/packages/orchestrator/internal/dns"
24+ "github.com/e2b-dev/infra/packages/orchestrator/internal/proxy"
2525 "github.com/e2b-dev/infra/packages/orchestrator/internal/sandbox/build"
2626 "github.com/e2b-dev/infra/packages/orchestrator/internal/sandbox/fc"
2727 "github.com/e2b-dev/infra/packages/orchestrator/internal/sandbox/nbd"
Original file line number Diff line number Diff line change @@ -7,14 +7,14 @@ import (
77 "context"
88 "errors"
99 "fmt"
10- "github.com/e2b-dev/infra/packages/orchestrator/internal/proxy"
1110 "net/http"
1211 "sync/atomic"
1312 "time"
1413
1514 "go.opentelemetry.io/otel/trace"
1615
1716 "github.com/e2b-dev/infra/packages/orchestrator/internal/dns"
17+ "github.com/e2b-dev/infra/packages/orchestrator/internal/proxy"
1818 "github.com/e2b-dev/infra/packages/orchestrator/internal/sandbox/build"
1919 "github.com/e2b-dev/infra/packages/orchestrator/internal/sandbox/nbd"
2020 "github.com/e2b-dev/infra/packages/orchestrator/internal/sandbox/network"
@@ -69,8 +69,8 @@ func (s *Sandbox) LoggerMetadata() sbxlogger.SandboxMetadata {
6969// Run cleanup functions for the already initialized resources if there is any error or after you are done with the started sandbox.
7070func NewSandbox (
7171
72- // YOU ARE IN SANDBOX_OTHER.GO
73- // YOU PROBABLY WANT TO BE IN SANDBOX_LINUX.GO
72+ // YOU ARE IN SANDBOX_OTHER.GO
73+ // YOU PROBABLY WANT TO BE IN SANDBOX_LINUX.GO
7474
7575 ctx context.Context ,
7676 tracer trace.Tracer ,
You can’t perform that action at this time.
0 commit comments