-
Notifications
You must be signed in to change notification settings - Fork 894
docs: improve workspaces and templates doc #9139
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from 6 commits
Commits
Show all changes
42 commits
Select commit
Hold shift + click to select a range
224bf4c
Reorg, updated/new screenshots, consistent terminology
marcpaq d494d28
First pass
marcpaq eabd21f
Another pass
marcpaq a92693d
Added integration section
marcpaq 46618e4
New outline for template pages, small updates
marcpaq 85535d0
Revised outline for templates, added tutorial
marcpaq bbd4928
First pass at tutorial
marcpaq 3cc2dbb
Some feedback from Ben.
marcpaq cb39a6d
Update docs/workspaces.md
marcpaq 6706032
Update docs/workspaces.md
marcpaq 4e4b9e5
Update docs/workspaces.md
marcpaq 351c457
Fixed typos
marcpaq 50e9041
Expanded tutorial
marcpaq ed27c28
New screenshots, improved tutorial, revised anatomy
marcpaq 744bad0
Improved tutorial. Anatomy is now a guided tour.
marcpaq 58d5c9e
First pass at guided tour
marcpaq bf5228c
Updated authentication info
marcpaq 92eea5f
Reorganized the guided tour
marcpaq 302f5dd
Edited more template pages
marcpaq c80c0e3
Update docs/templates/tour.md
marcpaq e308e5d
Update docs/templates/tour.md
marcpaq 22570dd
Update docs/templates/tour.md
marcpaq cbeac94
Update docs/templates/tutorial.md
marcpaq b12c1d6
Update docs/templates/tour.md
marcpaq b4f33d5
Update docs/templates/tour.md
marcpaq ec1741e
Update docs/templates/tour.md
marcpaq 223dc9a
Update docs/templates/tour.md
marcpaq cb266c6
Update docs/templates/tour.md
marcpaq b5c0371
Revised devcontainers and docker-in-workspaces
marcpaq 9f16953
Edited and added screenshots
marcpaq 6bda970
Prepared first draft, except docs/templates/open-in-coder.md
marcpaq c2d992b
Fix typo
marcpaq c9a6c3c
remove legacy parameters and migration guide
matifali 3efae01
Use coder templates create
marcpaq 267639c
Added screenshot for workspace template variables
marcpaq 5c64352
Made it prettier
marcpaq dbfc80d
Fixed minor typos and markdown problems
marcpaq 6506168
edits to repairing workspaces
bpmct 588a08a
fix broken links in product
bpmct 151687d
Added troubleshooting, minor corrections.
marcpaq 456f5d5
fix terminal links
bpmct 59528ff
fmt
matifali File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
# Creating, editing, and updating templates | ||
|
||
You create and edit Coder templates as [Terraform](./concepts.md) configuration files (`.tf`). | ||
|
||
## Who creates templates? | ||
|
||
The [Template Admin](../admin/users.md) role (and above) can create templates. End users (developers) create workspaces from them. | ||
|
||
Templates can also be [managed witg git](./change-management.md), allowing any developer to propose changes to a template. | ||
|
||
> [Template RBAC](../admin/rbac.md) allows you to give different users & groups access to templates. | ||
|
||
## Starter templates | ||
|
||
We provide starter templates for common cloud providers (e.g. AWS) and orchestrators (e.g. Kubernetes). From there, you can modify them with [Terraform](https://terraform.io) to use your own images, VPC, cloud credentials, etc. All Terraform resources and properties are supported, so fear not if your favorite cloud isn't here! | ||
|
||
 | ||
|
||
If you'd prefer to use the CLI, use `coder templates init`. | ||
|
||
> The Terraform code for our starter templates are avalible on our [GitHub](https://github.com/coder/coder/tree/main/examples/templates). | ||
|
||
## Editing templates | ||
|
||
Our starter templates are meant to be modified work for your use cases! You can edit the Terraform code for a template directly in the UI. | ||
|
||
 | ||
|
||
If you'd prefer to use the CLI, use `coder templates pull` and `coder templates push`. | ||
|
||
> Even if you are a Terraform expert, we suggest reading our full guide on [writing Coder templates](./managing.md). | ||
|
||
## Updating templates | ||
|
||
Templates are versioned, keeping all developer workspaces up-to-date. When a new version is published, developers are notified to get the latest infrastructure, software, or security patches. | ||
|
||
 | ||
|
||
## Next step | ||
marcpaq marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
- [Your first templates](./tutorial.md) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Customizing templates | ||
|
||
You can give developers more information and control over their workspaces: | ||
|
||
* [Agent metadata](./agent-metadata.md): Show metrics about the running workspace. | ||
* [Resource metadata](./resource-metadata.md): Show information about a workspace's resources. | ||
* [Parameters](./parameters.md): Let the user customize their workspace. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,52 +1,7 @@ | ||
# Templates | ||
|
||
Templates define the underlying infrastructure that workspaces run on. All Coder workspaces are created from a | ||
template. | ||
Templates define the underlying infrastructure that workspaces run on. | ||
All Coder [workspaces](./workspaces.md) are created from a template. | ||
|
||
## Who creates templates? | ||
|
||
The [Template Admin](../admin/users.md) role (and above) can create templates. End users (developers) create workspaces from them. However, templates can also be [managed via git](./change-management.md), allowing any developer to propose changes to a template. | ||
|
||
> [Template RBAC](../admin/rbac.md) allows you to give different users & groups access to templates. | ||
|
||
## Starter templates | ||
|
||
We provide starter templates for common cloud providers (e.g. AWS) and orchestrators (e.g. Kubernetes). From there, you can modify them with [Terraform](https://terraform.io) to use your own images, VPC, cloud credentials, etc. All Terraform resources and properties are supported, so fear not if your favorite cloud isn't here! | ||
|
||
 | ||
|
||
If you'd prefer to use the CLI, use `coder templates init`. | ||
|
||
> The Terraform code for our starter templates are avalible on our [GitHub](https://github.com/coder/coder/tree/main/examples/templates). | ||
|
||
## Editing templates | ||
|
||
Our starter templates are meant to me modified work for your use cases! You can edit the Terraform code for a template directly in the UI. | ||
|
||
 | ||
|
||
|
||
If you'd prefer to use the CLI, use `coder templates pull` and `coder templates push`. | ||
|
||
> Even if you are a Terraform expert, we suggest reading our full guide on [writing Coder templates](./managing.md). | ||
|
||
## Template updates | ||
|
||
Templates are versioned, keeping all developer workspaces up-to-date. When a new version is published, developers are notified to get the latest infrastructure, software, or security patches. | ||
|
||
 | ||
|
||
## Template parameters | ||
|
||
You'll likely want to hardcode certain properties for workspaces (e.g. "security group, VPC"). Others can be exposed via parameters to give developers flexibility (e.g. instance size, GitHub repo URL). | ||
|
||
Paramaters let users customize their individual workspaces: | ||
|
||
 | ||
|
||
> Paramaters are defined via the template's Terraform code. [Learn more](./parameters.md) | ||
|
||
## Next steps | ||
|
||
- [Template structure](./structure.md) | ||
- [Template structure](./structure.md) | ||
<children> | ||
</children> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
# Your first template | ||
|
||
## Install Docker | ||
|
||
## Install Coder | ||
|
||
## Choose a starter template | ||
|
||
## Creating a template for Kubernetes | ||
|
||
## Next steps | ||
|
||
- [Anatomy of a template](./anatomy.md) | ||
- [Setting up templates](./best-practices.md) |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.