mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
feat: allow setting port share protocol (#12383)
Co-authored-by: Garrett Delfosse <garrett@coder.com>
This commit is contained in:
co-authored by
Garrett Delfosse
parent
23ff807a27
commit
46a2ff1061
Generated
+2
@@ -57,6 +57,7 @@ curl -X POST http://coder-server:8080/api/v2/workspaces/{workspace}/port-share \
|
||||
{
|
||||
"agent_name": "string",
|
||||
"port": 0,
|
||||
"protocol": "http",
|
||||
"share_level": "owner"
|
||||
}
|
||||
```
|
||||
@@ -76,6 +77,7 @@ curl -X POST http://coder-server:8080/api/v2/workspaces/{workspace}/port-share \
|
||||
{
|
||||
"agent_name": "string",
|
||||
"port": 0,
|
||||
"protocol": "http",
|
||||
"share_level": "owner",
|
||||
"workspace_id": "0967198e-ec7b-4c6b-b4d3-f71244cadbe9"
|
||||
}
|
||||
|
||||
Generated
+51
-11
@@ -6613,17 +6613,29 @@ If the schedule is empty, the user will be updated to use the default schedule.|
|
||||
{
|
||||
"agent_name": "string",
|
||||
"port": 0,
|
||||
"protocol": "http",
|
||||
"share_level": "owner"
|
||||
}
|
||||
```
|
||||
|
||||
### Properties
|
||||
|
||||
| Name | Type | Required | Restrictions | Description |
|
||||
| ------------- | ------------------------------------------------------------------------------ | -------- | ------------ | ----------- |
|
||||
| `agent_name` | string | false | | |
|
||||
| `port` | integer | false | | |
|
||||
| `share_level` | [codersdk.WorkspaceAgentPortShareLevel](#codersdkworkspaceagentportsharelevel) | false | | |
|
||||
| Name | Type | Required | Restrictions | Description |
|
||||
| ------------- | ------------------------------------------------------------------------------------ | -------- | ------------ | ----------- |
|
||||
| `agent_name` | string | false | | |
|
||||
| `port` | integer | false | | |
|
||||
| `protocol` | [codersdk.WorkspaceAgentPortShareProtocol](#codersdkworkspaceagentportshareprotocol) | false | | |
|
||||
| `share_level` | [codersdk.WorkspaceAgentPortShareLevel](#codersdkworkspaceagentportsharelevel) | false | | |
|
||||
|
||||
#### Enumerated Values
|
||||
|
||||
| Property | Value |
|
||||
| ------------- | --------------- |
|
||||
| `protocol` | `http` |
|
||||
| `protocol` | `https` |
|
||||
| `share_level` | `owner` |
|
||||
| `share_level` | `authenticated` |
|
||||
| `share_level` | `public` |
|
||||
|
||||
## codersdk.User
|
||||
|
||||
@@ -7579,6 +7591,7 @@ If the schedule is empty, the user will be updated to use the default schedule.|
|
||||
{
|
||||
"agent_name": "string",
|
||||
"port": 0,
|
||||
"protocol": "http",
|
||||
"share_level": "owner",
|
||||
"workspace_id": "0967198e-ec7b-4c6b-b4d3-f71244cadbe9"
|
||||
}
|
||||
@@ -7586,12 +7599,23 @@ If the schedule is empty, the user will be updated to use the default schedule.|
|
||||
|
||||
### Properties
|
||||
|
||||
| Name | Type | Required | Restrictions | Description |
|
||||
| -------------- | ------------------------------------------------------------------------------ | -------- | ------------ | ----------- |
|
||||
| `agent_name` | string | false | | |
|
||||
| `port` | integer | false | | |
|
||||
| `share_level` | [codersdk.WorkspaceAgentPortShareLevel](#codersdkworkspaceagentportsharelevel) | false | | |
|
||||
| `workspace_id` | string | false | | |
|
||||
| Name | Type | Required | Restrictions | Description |
|
||||
| -------------- | ------------------------------------------------------------------------------------ | -------- | ------------ | ----------- |
|
||||
| `agent_name` | string | false | | |
|
||||
| `port` | integer | false | | |
|
||||
| `protocol` | [codersdk.WorkspaceAgentPortShareProtocol](#codersdkworkspaceagentportshareprotocol) | false | | |
|
||||
| `share_level` | [codersdk.WorkspaceAgentPortShareLevel](#codersdkworkspaceagentportsharelevel) | false | | |
|
||||
| `workspace_id` | string | false | | |
|
||||
|
||||
#### Enumerated Values
|
||||
|
||||
| Property | Value |
|
||||
| ------------- | --------------- |
|
||||
| `protocol` | `http` |
|
||||
| `protocol` | `https` |
|
||||
| `share_level` | `owner` |
|
||||
| `share_level` | `authenticated` |
|
||||
| `share_level` | `public` |
|
||||
|
||||
## codersdk.WorkspaceAgentPortShareLevel
|
||||
|
||||
@@ -7609,6 +7633,21 @@ If the schedule is empty, the user will be updated to use the default schedule.|
|
||||
| `authenticated` |
|
||||
| `public` |
|
||||
|
||||
## codersdk.WorkspaceAgentPortShareProtocol
|
||||
|
||||
```json
|
||||
"http"
|
||||
```
|
||||
|
||||
### Properties
|
||||
|
||||
#### Enumerated Values
|
||||
|
||||
| Value |
|
||||
| ------- |
|
||||
| `http` |
|
||||
| `https` |
|
||||
|
||||
## codersdk.WorkspaceAgentPortShares
|
||||
|
||||
```json
|
||||
@@ -7617,6 +7656,7 @@ If the schedule is empty, the user will be updated to use the default schedule.|
|
||||
{
|
||||
"agent_name": "string",
|
||||
"port": 0,
|
||||
"protocol": "http",
|
||||
"share_level": "owner",
|
||||
"workspace_id": "0967198e-ec7b-4c6b-b4d3-f71244cadbe9"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user