Skip to content
This repository was archived by the owner on Oct 20, 2023. It is now read-only.

Commit e87e332

Browse files
authored
finish readme
1 parent efb71d2 commit e87e332

File tree

2 files changed

+131
-18
lines changed

2 files changed

+131
-18
lines changed

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2021 GitHub
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 110 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,15 @@
1-
## Codespaces Network Bridge GitHub CLI extension
1+
## [🧪 Preview] Codespaces Network Bridge
2+
3+
<img width="749" alt="image" src="https://user-images.githubusercontent.com/1478800/161617508-b65de564-60f3-46c8-8394-5b28c8ac477b.png">
4+
5+
6+
🧪 *This extension is currently in Preview stage, so some hiccups are expected. Please help us to improve by submitting feedback!*
27

38
This [GitHub CLI](https://cli.github.com/) extension allows to bridge network between a Codespace and your local machine, so the `Codespace` can reach out to any remote resource that is reachable from your machine. In another words, it uses your local machine a network `gateway` to get to those resources.
49

510
For instance, if you are using `VPN` to connect to your enterprise network to access a database or any other remote resources on the private network, this extension allows you to get to those resources from whithin a Codespace also, so you can develop fully inside a Codespace!
611

7-
[About GitHub CLI](https://cli.github.com/)
12+
[About GitHub CLI](https://cli.github.com/).
813

914
## Installation
1015

@@ -20,6 +25,14 @@ gh extension install legomushroom/gh-net
2025
<img width="749" alt="image" src="https://user-images.githubusercontent.com/1478800/161620032-c999de5a-7445-4662-bedd-95be830556e9.png">
2126
</details>
2227

28+
<br />
29+
30+
Picking up new extension version:
31+
32+
```shell
33+
gh extension upgrade legomushroom/gh-net
34+
```
35+
2336
## Usage
2437

2538
To start network forwarding from whithin a Codespace to your local machine, run:
@@ -64,30 +77,28 @@ If such network interface is found, we create a local `network socket` and a `NA
6477

6578
For `DNS` packets, we register an address that is on `default gateway` subnet which allows to catch all unresolved `DNS` queries. Once `DNS` packet received, it is passed over to the `local machine` where request to local `DNS` resolver is made and reply sent back to the Codespace.
6679

67-
## Troubleshooting
68-
69-
Troubleshooting notes.
80+
The extension is written in `Rust` and provides high preformance, low memory footprint and memory safety, hence must cause low latency.
7081

7182
## Supported platforms
7283

7384
| Target platforms | Local | Inside Codespace |
7485
|-------------------------|-------|--------------|
7586
| Mac OSx (Intel) || 🙅 |
7687
| Mac OSx (Apple) | 🏃 | 🙅 |
77-
| Linux (Ubuntu) || |
78-
| Linux (Debian) || |
79-
| Linux (Fedora) || |
80-
| Linux (Red Hat) || |
81-
| Linux (Mint) || |
82-
| Linux (OpenSUSE) || |
83-
| Linux (Centos) || |
84-
| Linux (Kali) || |
85-
| Linux (Raspberry Pi OS) || |
88+
| Linux (Ubuntu) |||
89+
| Linux (Debian) |||
90+
| Linux (Fedora) |||
91+
| Linux (Red Hat) |||
92+
| Linux (Mint) |||
93+
| Linux (OpenSUSE) |||
94+
| Linux (Centos) |||
95+
| Linux (Kali) |||
96+
| Linux (Raspberry Pi OS) |||
8697
| Windows 10 | 🏃 | 🙅 |
8798

8899
✅ - currently supported 🏃 - support in progress 🙅 - not applicable
89100

90-
### DNS
101+
### DNS Record Type Support
91102

92103
| DNS Record Type | Status |
93104
|-----------------|--------|
@@ -102,12 +113,93 @@ Troubleshooting notes.
102113
| MX ||
103114
| ANY ||
104115

105-
## Other GitHub CLI extensions for Codespaces
116+
### Transport layer protocol support
117+
118+
Currently only `TCP`, `UDP` and `ICMP` protocols were tested extensivelly:
119+
120+
| Transport protocol | Status |
121+
|--------------------|--------|
122+
| TCP ||
123+
| UDP ||
124+
| ICMP ||
125+
| SCTP | ? |
126+
| DCCP | ? |
127+
| RSVP | ? |
128+
| QUIC | ? |
129+
130+
### Network layer protocol support
131+
132+
Currently only `IPv4` is supported and was tested extensivelly:
133+
134+
| Network protocol | Status |
135+
|--------------------|--------|
136+
| IPv4 ||
137+
| IPv6 | ? |
138+
| ICMPv6 | ? |
139+
| IGMP | ? |
140+
| NDP | ? |
141+
| ECN | ? |
142+
| IPSec | ? |
143+
144+
## Troubleshooting
145+
146+
- Create a [Bug report](https://github.com/legomushroom/gh-net/issues/new?assignees=&labels=bug&template=bug_report.md&title=).
147+
- Create a [Feature request](https://github.com/legomushroom/gh-net/issues/new?assignees=&labels=enhancement&template=feature_request.md&title=).
148+
149+
Please search for existing issues before creating a new one.
150+
151+
### Known issues
152+
153+
> My local machine network configuration has changed but extension does not pick up the changes.
154+
155+
- Please restart the extension by pressing `q` and connecting to the Codespace again. The extension currently does not watch for changes in network configuration and hence does not detect new network interfaces or changes in interfaces config. This will be fixed in the future.
156+
157+
> I'm getting an error an a stack trace immediatelly after starting the extension.
158+
159+
- Most likely you forgot to use `sudo` to run the extension. If `sudo` was used, please create a [Bug report](https://github.com/legomushroom/gh-net/issues/new?assignees=&labels=bug&template=bug_report.md&title=).
160+
161+
> Extension suddenly stops working after some time and I see some stack traces in the console.
162+
163+
Most likely `SSH` connection was dropped or there was an intermittent network issue on your machine. The extension does not currently reconnects to the Codespace automatically. This will be fixed in the future. If this happens too often, please create a [Bug report](https://github.com/legomushroom/gh-net/issues/new?assignees=&labels=bug&template=bug_report.md&title=).
164+
165+
> I'm trying to send `Ethernet Datagrams`(L2 network layer) directly and expect those to be forwarded but they are not.
166+
167+
The extension currently forwards `IP`(L3 network layer) traffic and above. If the datagrams contain `IP` packets that are addressed to a remote resource addressible from your local machine it should work. If it does not, please create a [Bug report](https://github.com/legomushroom/gh-net/issues/new?assignees=&labels=bug&template=bug_report.md&title=). If you want to send `Ethernet Datagrams` directly, please create a [Feature request](https://github.com/legomushroom/gh-net/issues/new?assignees=&labels=enhancement&template=feature_request.md&title=), we would love to know about your use case!
168+
169+
> I'm using some transport protocol that does not work.
170+
171+
Currently `TCP`/`UDP` and `ICMP` are supported. Other protocols should work but were not tested extensivelly. Please create [Bug report](https://github.com/legomushroom/gh-net/issues/new?assignees=&labels=bug&template=bug_report.md&title=) so we can address the issue.
172+
173+
## Useful links
106174

107-
- [Codespace Compose](https://github.com/github/gh-codespace-compose)
108175
- [About GitHub CLI](https://cli.github.com/)
109176
- [GitHub CLI Docs](https://cli.github.com/manual/gh)
177+
- [About GitHub Codespaces](https://github.com/features/codespaces)
178+
179+
- [🔒 Source code](https://github.com/github/codespaces-vpn-gateway)
180+
- [🔒 Codespace Compose GitHub CLI extension](https://github.com/github/gh-codespace-compose)
110181

111182
## License
112183

113-
License text.
184+
MIT License
185+
186+
Copyright (c) 2021 GitHub
187+
188+
Permission is hereby granted, free of charge, to any person obtaining a copy
189+
of this software and associated documentation files (the "Software"), to deal
190+
in the Software without restriction, including without limitation the rights
191+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
192+
copies of the Software, and to permit persons to whom the Software is
193+
furnished to do so, subject to the following conditions:
194+
195+
The above copyright notice and this permission notice shall be included in all
196+
copies or substantial portions of the Software.
197+
198+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
199+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
200+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
201+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
202+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
203+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
204+
SOFTWARE.
205+

0 commit comments

Comments
 (0)