Skip to content

Commit e572fef

Browse files
committed
Make gen
1 parent 42f8154 commit e572fef

File tree

6 files changed

+179
-15
lines changed

6 files changed

+179
-15
lines changed

coderd/apidoc/docs.go

Lines changed: 63 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

coderd/apidoc/swagger.json

Lines changed: 55 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/api/enterprise.md

Lines changed: 55 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1191,7 +1191,7 @@ curl -X GET http://coder-server:8080/api/v2/workspaceproxies \
11911191
"errors": ["string"],
11921192
"warnings": ["string"]
11931193
},
1194-
"status": "reachable"
1194+
"status": "ok"
11951195
},
11961196
"updated_at": "2019-08-24T14:15:22Z",
11971197
"url": "string",
@@ -1232,7 +1232,7 @@ Status Code **200**
12321232

12331233
| Property | Value |
12341234
| -------- | -------------- |
1235-
| `status` | `reachable` |
1235+
| `status` | `ok` |
12361236
| `status` | `unreachable` |
12371237
| `status` | `unhealthy` |
12381238
| `status` | `unregistered` |
@@ -1286,7 +1286,7 @@ curl -X POST http://coder-server:8080/api/v2/workspaceproxies \
12861286
"errors": ["string"],
12871287
"warnings": ["string"]
12881288
},
1289-
"status": "reachable"
1289+
"status": "ok"
12901290
},
12911291
"updated_at": "2019-08-24T14:15:22Z",
12921292
"url": "string",
@@ -1302,6 +1302,58 @@ curl -X POST http://coder-server:8080/api/v2/workspaceproxies \
13021302

13031303
To perform this operation, you must be authenticated. [Learn more](authentication.md).
13041304

1305+
## Get workspace proxy
1306+
1307+
### Code samples
1308+
1309+
```shell
1310+
# Example request using curl
1311+
curl -X GET http://coder-server:8080/api/v2/workspaceproxies/{workspaceproxy} \
1312+
-H 'Accept: application/json' \
1313+
-H 'Coder-Session-Token: API_KEY'
1314+
```
1315+
1316+
`GET /workspaceproxies/{workspaceproxy}`
1317+
1318+
### Parameters
1319+
1320+
| Name | In | Type | Required | Description |
1321+
| ---------------- | ---- | ------------ | -------- | ---------------- |
1322+
| `workspaceproxy` | path | string(uuid) | true | Proxy ID or name |
1323+
1324+
### Example responses
1325+
1326+
> 200 Response
1327+
1328+
```json
1329+
{
1330+
"created_at": "2019-08-24T14:15:22Z",
1331+
"deleted": true,
1332+
"icon": "string",
1333+
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
1334+
"name": "string",
1335+
"status": {
1336+
"checked_at": "2019-08-24T14:15:22Z",
1337+
"report": {
1338+
"errors": ["string"],
1339+
"warnings": ["string"]
1340+
},
1341+
"status": "ok"
1342+
},
1343+
"updated_at": "2019-08-24T14:15:22Z",
1344+
"url": "string",
1345+
"wildcard_hostname": "string"
1346+
}
1347+
```
1348+
1349+
### Responses
1350+
1351+
| Status | Meaning | Description | Schema |
1352+
| ------ | ------------------------------------------------------- | ----------- | ------------------------------------------------------------ |
1353+
| 200 | [OK](https://tools.ietf.org/html/rfc7231#section-6.3.1) | OK | [codersdk.WorkspaceProxy](schemas.md#codersdkworkspaceproxy) |
1354+
1355+
To perform this operation, you must be authenticated. [Learn more](authentication.md).
1356+
13051357
## Delete workspace proxy
13061358

13071359
### Code samples

docs/api/schemas.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3454,7 +3454,7 @@ Parameter represents a set value for the scope.
34543454
## codersdk.ProxyHealthStatus
34553455

34563456
```json
3457-
"reachable"
3457+
"ok"
34583458
```
34593459

34603460
### Properties
@@ -3463,7 +3463,7 @@ Parameter represents a set value for the scope.
34633463

34643464
| Value |
34653465
| -------------- |
3466-
| `reachable` |
3466+
| `ok` |
34673467
| `unreachable` |
34683468
| `unhealthy` |
34693469
| `unregistered` |
@@ -5338,7 +5338,7 @@ Parameter represents a set value for the scope.
53385338
"errors": ["string"],
53395339
"warnings": ["string"]
53405340
},
5341-
"status": "reachable"
5341+
"status": "ok"
53425342
},
53435343
"updated_at": "2019-08-24T14:15:22Z",
53445344
"url": "string",
@@ -5369,7 +5369,7 @@ Parameter represents a set value for the scope.
53695369
"errors": ["string"],
53705370
"warnings": ["string"]
53715371
},
5372-
"status": "reachable"
5372+
"status": "ok"
53735373
}
53745374
```
53755375

enterprise/coderd/workspaceproxy.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -401,9 +401,7 @@ func (api *API) workspaceProxyRegister(rw http.ResponseWriter, r *http.Request)
401401
// @Router /workspaceproxies/me/goingaway [post]
402402
// @x-apidocgen {"skip": true}
403403
func (api *API) workspaceProxyGoingAway(rw http.ResponseWriter, r *http.Request) {
404-
var (
405-
ctx = r.Context()
406-
)
404+
ctx := r.Context()
407405

408406
// Force a health update to happen immediately. The proxy should
409407
// not return a successful response if it is going away.

enterprise/coderd/workspaceproxy_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ func TestRegions(t *testing.T) {
213213
proxy := coderdenttest.NewWorkspaceProxy(t, api, client, &coderdenttest.ProxyOptions{
214214
Name: proxyName,
215215
})
216-
var _ = proxy
216+
_ = proxy
217217

218218
require.Eventuallyf(t, func() bool {
219219
proxy, err := client.WorkspaceProxyByName(ctx, proxyName)

0 commit comments

Comments
 (0)