-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Workspace, configmap, secret and typing #4055
Comments
/cc @sbwsg |
I've received some requests to allow a workspace declaration to specify a minimum required size for the volume. Also digest info for specific file paths on a workspace. I'm generally in favor of something to let users shape their workspaces better. Would also definitely like to make it Volume-agnostic so that we're not embedding more k8s-specific stuff than what's already in Tags or validation helpers of some kind? Here's a hand-wavey bit of YAML: kind: Task
spec:
workspaces:
- name: source
requirements:
- storage: persistent # tell tekton the volume must retain data across tasks. other options: "ephemeral"
- minSize: 256M
- writeable: true # this task plans to put content on the volume
- digests:
/path/to/foo: abcdef123 # entrypoint can check these?
/path/to/bar: ghijkl456 In regards the "meaning", something like:
Or maybe the Edit after API WG: Vincent mentioned that the problem feels like it's maybe more with Pipelines than Tasks. |
This looks like a reasonable set of classifications to start with. How might they be used by a Pipeline author? And how could an integrator leverage this type information? kind: Pipeline
spec:
workspaces:
- name: source
type: shared-data
- name: dependency-cache
type: cache
- name: build-artifacts
type: shared-data # Maybe we want a specific output-artifacts type?
- name: ssh-credentials
type: credential
- name: lint-settings
type: config |
That's up to them, but it would give some hints to the integrator on what to "hook" to these workspaces (using some labels or whatever, it's out of pipeline's reach). |
Hm, I meant more like, "If someone writes a TEP for this, what do we put in the Use Cases section?" At the moment I don't think we have any actual concrete use cases. |
Issues go stale after 90d of inactivity. /lifecycle stale Send feedback to tektoncd/plumbing. |
Stale issues rot after 30d of inactivity. /lifecycle rotten Send feedback to tektoncd/plumbing. |
/remove-lifecycle rotten |
Issues go stale after 90d of inactivity. /lifecycle stale Send feedback to tektoncd/plumbing. |
/lifecycle frozen |
As a user, and an integrator of Tekton, I find something a bit unsettling with the way we made
Workspace
work.We are using
Workspace
for two type of operation: sharing data between task and providing something required by the task (config, secret, cache, …) that is not readable.When writing a
Task
, there is no way to convey which type of workspace is what. Let's assume I am taking 4 workspaces, one for sharing data (thesource
), one to get some credential (thesecret
), one optional to get some tooling configuration (theconfigmap
) and another optional to provide some cache (thecache
). Except from reading the name, there is no way to know that the firstWorkspace
should be writable and the rest should not, or that the first or last ones might or might not need to be provisionned (aka could be empty) but the 2 others (secret
andconfigmap
) should contain something, and something specific even.This is getting even more trickier when integrating Tekton, if, for example, we want to provide our user a way to not have to care too much about the sharing data workspace and have some sane defaults around here. As of today, there is no way, from a
Pipeline
or aTask
definition, to know that this (or these) workspace(s) should be writable and those should not. Thus it makes it really hard to provide a defaultWorkspace
to our users.I don't have especially strong thoughts around how to fix that, but here is a few ideas:
Workspace
solely for sharing data, and make thesecret
/configmap
handling more explicit in Tekton (aka having a field or set of fields dedicated to them) — question is open if we could use volumes for handling them (see Towards v1 API #3548 (comment)).Workspace
aka be able to say "this is for sharing data, this is for configuration or secrets", … It would ties it to any type of volume behind the scene (letting this up to the user still), but it would help tools interact a bit more.Workspace
in definitions, a bit like metadatas (labels ?). Idea here would be that, by convention, we could "label" a workspace asmain
(the main sharing data workspace), on withcache
or `credentials", …/kind feature
/kind discussions
The text was updated successfully, but these errors were encountered: