|
1 | 1 | # devbox cloud forward
|
2 |
| -Port forwards a local port to a remote devbox cloud port. |
3 | 2 |
|
4 |
| -## Synopsis |
| 3 | +Port forwards a local port to a remote devbox cloud port. If 0 or no local port is specified, we find a suitable local port. Use 'stop' to stop all port forwards. |
5 | 4 |
|
| 5 | +```bash |
| 6 | +devbox cloud forward <local-port>:<remote-port> | :<remote-port> | stop | list [flags] |
| 7 | +``` |
6 | 8 |
|
| 9 | +## Examples |
7 | 10 |
|
8 | 11 | ```bash
|
9 | 12 | # Connect remote port 3000 to an automatically assigned local port
|
10 | 13 | $ devbox cloud forward :3000
|
11 | 14 | Port forwarding 54653:3000
|
12 | 15 | To view in browser, visit http://localhost:54653
|
13 | 16 | ```
|
| 17 | + |
14 | 18 | ```bash
|
15 | 19 | # Connect remote port 3000 to local port 3000
|
16 | 20 | $ devbox cloud forward 3000:3000
|
17 | 21 | Port forwarding 3000:3000
|
18 | 22 | To view in browser, visit http://localhost:3000
|
19 | 23 | ```
|
| 24 | + |
20 | 25 | ```bash
|
21 | 26 | # Close all open port-forwards
|
22 | 27 | $ devbox cloud forward stop
|
23 | 28 | ```
|
24 | 29 |
|
25 |
| -Usage: |
26 |
| - devbox cloud forward \<local-port\>:\<remote-port\> | :\<remote-port\> | stop | list [flags] |
27 |
| - devbox cloud forward [command] |
| 30 | +## Options |
28 | 31 |
|
29 |
| -Available Commands: |
30 |
| - list Lists all port forwards managed by devbox |
31 |
| - stop Stops all port forwards managed by devbox |
32 |
| - |
33 |
| -Flags: |
| 32 | +```text |
34 | 33 | -h, --help help for forward
|
| 34 | + -q, --quiet suppresses logs |
| 35 | +``` |
| 36 | + |
| 37 | +## SEE ALSO |
| 38 | + |
| 39 | +* [devbox cloud](devbox_cloud.md) - [Preview] Remote development environments on the cloud |
| 40 | +* [devbox cloud forward list](devbox_cloud_forward_list.md) - Lists all port forwards managed by devbox |
| 41 | +* [devbox cloud forward stop](devbox_cloud_forward_stop.md) - Stops all port forwards managed by devbox |
35 | 42 |
|
36 |
| -Global Flags: |
37 |
| - -q, --quiet suppresses logs. |
|
0 commit comments