Skip to content

Commit 2b5ab23

Browse files
committed
🤖 fix: auto-discover API reference kinds and nav
Auto-discover root API Kinds for docs/reference/api generation, wire resource/scope from CRD manifests, and sync MkDocs API nav from generated outputs. --- _Generated with `mux` • Model: `openai:gpt-5.3-codex` • Thinking: `xhigh` • Cost: `$0.45`_ <!-- mux-attribution: model=openai:gpt-5.3-codex thinking=xhigh costs=0.45 -->
1 parent d159bb6 commit 2b5ab23

4 files changed

Lines changed: 369 additions & 26 deletions

File tree

Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
<!-- Code generated by hack/update-reference-docs.sh using github.com/elastic/crd-ref-docs. DO NOT EDIT. -->
2+
3+
# `WorkspaceProxy`
4+
5+
## API identity
6+
7+
- Group/version: `coder.com/v1alpha1`
8+
- Kind: `WorkspaceProxy`
9+
- Resource: `workspaceproxies`
10+
- Scope: namespaced
11+
12+
## Spec
13+
14+
| Field | Type | Description |
15+
| --- | --- | --- |
16+
| `spec.image` | `string` | Image is the container image used for the workspace proxy pod. |
17+
| `spec.replicas` | `int32` | Replicas is the desired number of proxy pods. |
18+
| `spec.service` | `github.com/coder/coder-k8s/api/v1alpha1.ServiceSpec` | Service controls the service created in front of the workspace proxy. |
19+
| `spec.primaryAccessURL` | `string` | PrimaryAccessURL is the coderd URL the proxy should connect to. |
20+
| `spec.proxySessionTokenSecretRef` | `github.com/coder/coder-k8s/api/v1alpha1.SecretKeySelector` | ProxySessionTokenSecretRef points to a Secret key containing the proxy token. |
21+
| `spec.bootstrap` | `github.com/coder/coder-k8s/api/v1alpha1.ProxyBootstrapSpec` | Bootstrap optionally registers the proxy and mints a proxy token. |
22+
| `spec.derpOnly` | `bool` | DerpOnly configures the workspace proxy to only serve DERP traffic. |
23+
| `spec.extraArgs` | `[]string` | ExtraArgs are appended to the default workspace proxy arguments. |
24+
| `spec.extraEnv` | `[]k8s.io/api/core/v1.EnvVar` | ExtraEnv are injected into the workspace proxy container. |
25+
| `spec.imagePullSecrets` | `[]k8s.io/api/core/v1.LocalObjectReference` | ImagePullSecrets are used by the pod to pull private images. |
26+
27+
## Status
28+
29+
| Field | Type | Description |
30+
| --- | --- | --- |
31+
| `status.observedGeneration` | `int64` | ObservedGeneration tracks the spec generation this status reflects. |
32+
| `status.readyReplicas` | `int32` | ReadyReplicas is the number of ready pods observed in the deployment. |
33+
| `status.registered` | `bool` | Registered reports whether bootstrap registration completed successfully. |
34+
| `status.proxyTokenSecretRef` | `github.com/coder/coder-k8s/api/v1alpha1.SecretKeySelector` | ProxyTokenSecretRef is the Secret used for the proxy session token. |
35+
| `status.phase` | `string` | Phase is a high-level readiness indicator. |
36+
| `status.conditions` | `[]metav1.Condition` | Conditions are Kubernetes-standard conditions for this resource. |
37+
38+
## Source
39+
40+
- Go type: `api/v1alpha1/workspaceproxy_types.go`
41+
- Generated CRD: `config/crd/bases/coder.com_workspaceproxies.yaml`

‎hack/crd-ref-docs/templates/markdown/gv_list.tpl‎

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,11 @@
3131
{{- $scope = "namespaced" -}}
3232
{{- end -}}
3333

34+
{{- $resource := markdownTemplateValue "resource" -}}
35+
{{- if eq $resource "" -}}
36+
{{- $resource = printf "%ss" (lower $kind) -}}
37+
{{- end -}}
38+
3439
{{- $gv := index $groupVersions 0 -}}
3540
{{- $rootType := $gv.TypeForKind $kind -}}
3641
{{- if not $rootType -}}
@@ -65,7 +70,7 @@
6570

6671
- Group/version: `{{ $rootType.GVK.Group }}/{{ $rootType.GVK.Version }}`
6772
- Kind: `{{ $rootType.GVK.Kind }}`
68-
- Resource: `{{ printf "%ss" (lower $kind) }}`
73+
- Resource: `{{ $resource }}`
6974
- Scope: {{ $scope }}
7075

7176
## Spec

0 commit comments

Comments
 (0)