Business Port Preview
About 162 wordsLess than 1 minute
Services running in the Workspaces environment can be previewed by accessing business ports through WebIDE or VSCode/Cursor client.
Method 1: WebIDE Port Mapping
When using WebIDE, add port mappings in the PORTS panel of the console, and the accessible URL will be generated automatically.
The business port URL can be obtained in two ways:
- From the PORTS panel in the WebIDE console
- From the environment variable
CNB_VSCODE_PROXY_URI. For example:https://xxxxxxxxxx-{{port}}.cnb.run, replace{{port}}with the actual port number.
Tips
Note: The service must be started on 0.0.0.0 to be accessible via this method. Services started on localhost or 127.0.0.1 cannot use this method.
Method 2: VSCode/Cursor Port Forwarding
Use the Port Forward feature of the VSCode/Cursor client to forward business ports to your local machine.