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
If I could set a template as backed by a git ref, change management is dead simple. Iteration shouldn't suffer as template update is replaced by git push.
CI automation (e.g pushing a Docker image with each template) also becomes simpler.
We should do the "Open in Coder" button alongside this as well. Keep in mind that this button should support specifying a path within the repository, as multiple templates can coexist in one repo.
Our VCS support should allow multiple URLs for the same template and create a union of all files. That allows them to have separate governance for individual subsets of files, for instance to more tightly limit who has access to sensitive data contained in one file.
So, our whole model becomes more complex when we assume that sensitive data will be in both the templates and the provisioner environment. See our recommended approach to secrets here.
Most git providers support CODEOWNERS so they can finely control edit access in the repo without us adding an additional feature.
I really like the idea of git-backed templates since I think that's the way that most people that are seriously using the product are going to want to source-control their workspace configuration. Some thoughts on how this would be implemented:
Are we introducing a new template "type" or are we doing away with our current model of coderd hosting the template archives? Eliminating the current model is the simplest way but it is backwards breaking (although I don't think we should care about this that much this early into the project).
Only git-backed templates also makes the initial experience more arduous. Right now a user downloads coderd, runs like 3 commands, and they have a workspace. If we move to purely git and a user needs to make some minor changes to our base templates, then they have to setup an oauth app or github/gitlab/bitbucket app (GitHub specifically is deprecating OAuth apps I'm pretty sure) in order for coderd to pull the template correctly. That's a lot of work to just check out the product.
If we introduce a new concept of "git templates" to sit alongside "local templates", then we have the added cognitive overhead of having to think through both flows whenever we want to make a change to templates. Commands like coder template push/pull also become conditional based on the template. Does template push/pull no-op for git-backed templates since it's all done via git?
It's worth mentioning that people can use git right now to version control their templates. Their CI would just run templates update or whatever. Obviously this still allows a user to potentially accidentally overwrite the wrong template, but maybe if we have finer-grained RBAC we can recommend that customers remove that permission for all users except whatever service account their CI is using.
This issue is becoming stale. In order to keep the tracker readable and actionable, I'm going close to this issue in 7 days if there isn't more activity.
This issue is becoming stale. In order to keep the tracker readable and actionable, I'm going close to this issue in 7 days if there isn't more activity.
Activity
[-]Add VCS-backed template[/-][+]Add Git-backed template[/+][-]Add Git-backed template[/-][+]Git-backed templates[/+]ketang commentedon Jul 14, 2022
Our VCS support should allow multiple URLs for the same template and create a union of all files. That allows them to have separate governance for individual subsets of files, for instance to more tightly limit who has access to sensitive data contained in one file.
ammario commentedon Jul 14, 2022
So, our whole model becomes more complex when we assume that sensitive data will be in both the templates and the provisioner environment. See our recommended approach to secrets here.
Most git providers support CODEOWNERS so they can finely control edit access in the repo without us adding an additional feature.
ketang commentedon Jul 14, 2022
Yeah. I'm not expressing a preference. I'm just predicting what customers will want.
Also, there are different kinds of sensitive data that may appear in templates. It's not just authentication secrets.
ketang commentedon Jul 14, 2022
Especially could be a concern interfacing with legacy systems that aren't compatible with more modern auth*.
sreya commentedon Jul 14, 2022
I really like the idea of git-backed templates since I think that's the way that most people that are seriously using the product are going to want to source-control their workspace configuration. Some thoughts on how this would be implemented:
Are we introducing a new template "type" or are we doing away with our current model of
coderdhosting the template archives? Eliminating the current model is the simplest way but it is backwards breaking (although I don't think we should care about this that much this early into the project).Only git-backed templates also makes the initial experience more arduous. Right now a user downloads
coderd, runs like 3 commands, and they have a workspace. If we move to purelygitand a user needs to make some minor changes to our base templates, then they have to setup an oauth app or github/gitlab/bitbucket app (GitHub specifically is deprecating OAuth apps I'm pretty sure) in order for coderd to pull the template correctly. That's a lot of work to just check out the product.If we introduce a new concept of "git templates" to sit alongside "local templates", then we have the added cognitive overhead of having to think through both flows whenever we want to make a change to templates. Commands like
coder template push/pullalso become conditional based on the template. Doestemplate push/pullno-op for git-backed templates since it's all done viagit?It's worth mentioning that people can use
gitright now to version control their templates. Their CI would just runtemplates updateor whatever. Obviously this still allows a user to potentially accidentally overwrite the wrong template, but maybe if we have finer-grained RBAC we can recommend that customers remove that permission for all users except whatever service account their CI is using.ammario commentedon Jul 15, 2022
@sreya all good concerns — perhaps we should resolve #2987 before this one?
[-]Git-backed templates[/-][+]RFC: Git-backed templates[/+]github-actions commentedon Oct 25, 2022
This issue is becoming stale. In order to keep the tracker readable and actionable, I'm going close to this issue in 7 days if there isn't more activity.
github-actions commentedon Apr 12, 2023
This issue is becoming stale. In order to keep the tracker readable and actionable, I'm going close to this issue in 7 days if there isn't more activity.