@@ -25,51 +25,24 @@ coder templates <create/update> <template-name>
25
25
26
26
## Parameters
27
27
28
- Templates often contain * parameters * . In Coder, there are two types of parameters:
28
+ Templates often contain _ parameters _ . In Coder, there are two types of parameters:
29
29
30
30
- ** Admin parameters** are set when a template is created/updated. These values
31
31
are often cloud secrets, such as a ` ServiceAccount ` token, and are annotated
32
- with ` sensitive = true ` in the template code.
33
-
32
+ with ` sensitive = true ` in the template code.
34
33
- ** User parameters** are set when a user creates a workspace. They are unique
35
34
to each workspace, often personalization settings such as "preferred region"
36
35
or "workspace image".
37
36
38
- ## Best Practices
39
-
40
- ### Template Changes
41
-
42
- We recommend source controlling your templates.
43
-
44
- ### Authenticating with Cloud Providers
45
-
46
- Coder's provisioner process needs to authenticate with cloud provider APIs to provision
47
- workspaces. We strongly advise against including credentials directly in your templates. You
48
- can either pass credentials to the provisioner as parameters, or execute Coder
49
- in an environment that is authenticated with the cloud provider.
37
+ ## Change Management
50
38
51
- We encourage the latter where supported. This approach simplifies the template, keeps cloud
52
- provider credentials out of Coder's database (making it a less valuable target for attackers),
53
- and is compatible with agent-based authentication schemes (that handle credential rotation
54
- and/or ensure the credentials are not written to disk).
39
+ We recommend source controlling your templates as you would other code.
55
40
56
- Cloud providers for which the Terraform provider supports authenticated environments include:
57
-
58
- - [ Google Cloud] ( https://registry.terraform.io/providers/hashicorp/google/latest/docs )
59
- - [ Amazon Web Services] ( https://registry.terraform.io/providers/hashicorp/aws/latest/docs )
60
- - [ Microsoft Azure] ( https://registry.terraform.io/providers/hashicorp/azurerm/latest/docs )
61
- - [ Kubernetes] ( https://registry.terraform.io/providers/hashicorp/kubernetes/latest/docs )
62
-
63
- Additional providers may be supported; check the
64
- [ documentation of the Terraform provider] ( https://registry.terraform.io/browse/providers ) for
65
- details.
66
-
67
- The way these generally work is via the credentials being available to Coder either in some
68
- well-known location on disk (e.g. ` ~/.aws/credentials ` for AWS on posix systems), or via
69
- environment variables. It is usually sufficient to authenticate using the CLI or SDK for the
70
- cloud provider before running Coder for this to work, but check the Terraform provider
71
- documentation for details.
41
+ CI is as simple as running ` coder templates update ` with the appropriate
42
+ credentials.
72
43
73
44
---
74
45
75
46
Next: [ Workspaces] ( ./workspaces.md )
47
+
48
+ Next: [ Authentication & Secrets] ( ./authentication.md )
0 commit comments