agent-substrate / agent-substrate/substrate

Add `kubectl ate proxy actor` for simple local connectivity

Đang mở
#213 1 bình luận 0 reaction 1 người được giao Được @Rachit-Gandhi nhận Xem trên GitHub
area/cli area/network kind/feature
Ngôn ngữ chính
Go
Star
1.8k
Fork
316
Merge trung bình
2 ngày 43 phút
Pull request đã merge (30 ngày)
287

Mô tả

In substrate's networking model, each actor gets a stable DNS name that can be resolved within the cluster. For a given actor, it's dns name is `.actors.resources.substrate.ate.dev`.

This all works fine when the client application is running within the cluster, as substrate augments the cluster DNS resolution to resolve `*.actors.resources.substrate.ate.dev` names. However, it introduces friction for actor developers when trying to connect to a given actor from outside the cluster, for example, from a local dev machine.

Something we could consider is adding a `kubectl ate proxy actor` command, which works similar to `kubectl proxy`.

When a user runs `kubectl ate proxy actor my-sandbox-1 --port:8080` we could start a reverse HTTP proxy on the given port, which injects the Host header for the actor (e.g. `Host: my-sandbox-2.actors.resources.substrate.k8s.io`) and sends the request to ate router (atenet).

Then the user can just run (using the sandbox demo app):

```
curl -X POST http://localhost:8888/process -H "Content-Type: application/json" -d '{"command": ["ls", "-la"]}'
```

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.