File tree Expand file tree Collapse file tree
sdk/src/beta9/abstractions Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -118,6 +118,10 @@ class Sandbox(Pod):
118118 # Docker daemon will be automatically started
119119 instance.docker.run("hello-world")
120120 ```
121+ ports (Optional[List[int]]):
122+ List of ports to expose from the sandbox. When specified, these ports will be accessible
123+ via public URLs upon sandbox creation. Default is an empty list. You can also dynamically
124+ expose ports at runtime using `instance.expose_port(port)`.
121125
122126 Example:
123127 ```python
@@ -160,6 +164,7 @@ def __init__(
160164 block_network : bool = False ,
161165 allow_list : Optional [List [str ]] = None ,
162166 docker_enabled : bool = False ,
167+ ports : Optional [List [int ]] = [],
163168 ):
164169 self .debug_buffer = io .StringIO ()
165170 self .sync_local_dir = sync_local_dir
@@ -179,6 +184,7 @@ def __init__(
179184 block_network = block_network ,
180185 allow_list = allow_list ,
181186 docker_enabled = docker_enabled ,
187+ ports = ports ,
182188 )
183189
184190 def debug (self ):
You can’t perform that action at this time.
0 commit comments