You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/tutorials/best-practices/speed-up-templates.md
+47-16Lines changed: 47 additions & 16 deletions
Original file line number
Diff line number
Diff line change
@@ -4,17 +4,22 @@ October 31, 2024
4
4
5
5
---
6
6
7
-
If it takes your workspace a long time to start, find out why and make some changes to your Coder templates to help speed things up.
7
+
If it takes your workspace a long time to start, find out why and make some
8
+
changes to your Coder templates to help speed things up.
8
9
9
10
## Monitoring
10
11
11
-
You can monitor [Coder logs](../../admin/monitoring/logs.md) through the system-native tools on your deployment platform, or stream logs to tools like Splunk, Datadog, Grafana Loki, and others.
12
+
You can monitor [Coder logs](../../admin/monitoring/logs.md) through the
13
+
system-native tools on your deployment platform, or stream logs to tools like
14
+
Splunk, Datadog, Grafana Loki, and others.
12
15
13
16
### Coder Observability Chart
14
17
15
-
Use the [Observability Helm chart](https://github.com/coder/observability) for a pre-built set of monitoring integrations.
18
+
Use the [Observability Helm chart](https://github.com/coder/observability) for a
19
+
pre-built set of monitoring integrations.
16
20
17
-
With the Observability Helm chart, you can monitor [which specific startup metrics are a part of the Helm chart?]
21
+
With the Observability Helm chart, you can monitor [which specific startup
Our observability bundle gives you this for free which is nice and has instructions on how to do it with Coder
33
+
Our observability bundle gives you this for free which is nice and has
34
+
instructions on how to do it with Coder
29
35
30
-
[Prometheus.io](https://prometheus.io/docs/introduction/overview/#what-is-prometheus) is included as part of the [observability chart](#coder-observability-chart).It offers a variety of [available metrics](../../admin/integrations/prometheus.md#available-metrics).
You can [install it separately](https://prometheus.io/docs/prometheus/latest/getting_started/) if you prefer.
41
+
You can
42
+
[install it separately](https://prometheus.io/docs/prometheus/latest/getting_started/)
43
+
if you prefer.
33
44
34
45
### Workspace build timeline
35
46
36
-
Use the **Build timeline** to monitor the time it takes to start specific workspaces. Identify long scripts, resources, and other things you can potentially optimize within the template.
47
+
Use the **Build timeline** to monitor the time it takes to start specific
48
+
workspaces. Identify long scripts, resources, and other things you can
49
+
potentially optimize within the template.
37
50
38
51

39
52
@@ -45,29 +58,45 @@ curl -X GET http://coder-server:8080/api/v2/workspacebuilds/{workspacebuild}/tim
45
58
-H 'Coder-Session-Token: API_KEY'
46
59
```
47
60
48
-
Visit the [API documentation](../../reference/api/builds.md#get-workspace-build-timings-by-id) for more information.
`coder server` defaults to three provisioner daemons. Each provisioner daemon can handle one single job, such as start, stop, or delete at a time and can be resource intensive. When all provisioners are busy, workspaces enter a "pending" state until a provisioner becomes available.
67
+
`coder server` defaults to three provisioner daemons. Each provisioner daemon
68
+
can handle one single job, such as start, stop, or delete at a time and can be
69
+
resource intensive. When all provisioners are busy, workspaces enter a "pending"
70
+
state until a provisioner becomes available.
53
71
54
72
### Increase provisioner daemons
55
73
56
-
Provisioners are queue-based to reduce unpredictable load to the Coder server. However, they can be scaled up to allow more concurrent provisioners. You risk overloading the central Coder server if you use too many local provisioners, so we recommend a maximum of five provisioners. For more than five provisioners, we recommend that you move to [external provisioners](../../admin/provisioners.md).
74
+
Provisioners are queue-based to reduce unpredictable load to the Coder server.
75
+
However, they can be scaled up to allow more concurrent provisioners. You risk
76
+
overloading the central Coder server if you use too many local provisioners, so
77
+
we recommend a maximum of five provisioners. For more than five provisioners, we
78
+
recommend that you move to [external provisioners](../../admin/provisioners.md).
57
79
58
-
If you can’t move to external provisioners, use the `provisioner-daemons` flag to increase the number of provisioner daemons to five:
80
+
If you can’t move to external provisioners, use the `provisioner-daemons` flag
81
+
to increase the number of provisioner daemons to five:
59
82
60
83
```shell
61
84
coder server --provisioner-daemons=5
62
85
```
63
86
64
-
Visit the [CLI documentation](../../reference/cli/server.md#--provisioner-daemons) for more information about increasing provisioner daemons and other options.
87
+
Visit the
88
+
[CLI documentation](../../reference/cli/server.md#--provisioner-daemons) for
89
+
more information about increasing provisioner daemons and other options.
65
90
66
91
### Adjust provisioner CPU/memory
67
92
68
-
We recommend that you deploy Coder to its own respective Kubernetes cluster, separate from production applications. Keep in mind that Coder runs development workloads, so the cluster should be deployed as such, without production-level configurations.
93
+
We recommend that you deploy Coder to its own respective Kubernetes cluster,
94
+
separate from production applications. Keep in mind that Coder runs development
95
+
workloads, so the cluster should be deployed as such, without production-level
96
+
configurations.
69
97
70
-
Adjust the CPU and memory values as shown in [Helm provisioner values.yaml](https://github.com/coder/coder/blob/main/helm/provisioner/values.yaml#L134-L141):
0 commit comments