Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [che-dev] Add metadata.namespace to Devfile
  • From: Lukas Krejci <lkrejci@xxxxxxxxxx>
  • Date: Thu, 7 Nov 2019 10:32:14 +0100
  • Autocrypt: addr=lkrejci@xxxxxxxxxx; keydata= mQENBF2dCOgBCAD5/JOv9+R+U/WliRugBDM39G42porWn4cxg3n0XnTsAPOGw4uEycm9qyYj PZ6Dx2/wWVFvjX1FOMFoSbiQF/7VsiafZy0g4a5J97SFTWZXwBqYqVInOfxHUFAegSqDEJ32 E7b8I/NivMl1/nIYgFogC1UJJ0TrfyjGeBKuXVPruTQeelqlQCi6Yoy43VoyZoWsYcrZQ9kc vDGvCAC2xkk42o8ARYuWNZkan8Q+KRLnroacAV07DslgTyBo1tobNw+uVzMhsbvK1HyVfjLt ceaBVFGy9CtTnZHY4zQ/aqjPdehZ6j53X7Mbzieckc81Rwm4PxojbWJ4pdVsjP2xHyTtABEB AAG0IUx1a2FzIEtyZWpjaSA8bGtyZWpjaUByZWRoYXQuY29tPokBVAQTAQgAPhYhBNUZeXTR D+fLJbwoiCLB0ImKMx/LBQJdnQjpAhsDBQkB4TOABQsJCAcCBhUKCQgLAgQWAgMBAh4BAheA AAoJECLB0ImKMx/LNh8IAJczCeBkCcGPTj+YVGvDR4Bs5YNv9FtNlrTI7J9MPx92QJRBYWfO REtHMBj0BaU663rJEA46Zr8rThAXWAAOKkUPWUZSqhzLSsbEeI2imtkADqDf9cpm5WtRnLoa t5L/EYRYhZjChnrCPaP9P+F5w5VtqepohvnRQiYeBPvzkQpkz0zyP/ynLT75mv4TJiUKrgQq zo+NRfCR/cpQna7cnT88FgDeMrI+qCBkIoLxiHjAKE9dTPHlyBPwb+f15WAOkoIYvvNWTZ5B MRAKMmYGm1PBh7zVzKGA/DTH3/rHlgzFeyksoDhPMdwSJuxlHztHwJQR+iixhWhPuQLi24xz F4y5AQ0EXZ0I6AEIAOKT6aZwXMRGUsU/aeuGP/i49BE9PoBXfcc94ReOHdpI7nPxH26YRras +SoYsFUl7WZiBoxtceLnP1mxLPXqlbKRCmCx7Td7LSB6btLiT6tc8rMmZ9CZMUd86DmAaEM8 yma+che9uSPdRFSOhI1V3mvHlslQ9O3UlGUWXY/G2v0T88lXsW874RXgtpnoMVArZmnkUzma 5ykTrz8+f1f/nPaJ3sPp6bMg56zW2NI2G+3wknu6c/QmRDXQ0XQUH4ZQ6Wd/Fjz2hdIpPyw4 e1b1OCVhkLsAOM5A9bMx7FBz1BYK+mc1mF+q58oKO3+gN0IVz8SPuhwKNc5cYIuvnMuSUGEA EQEAAYkBPAQYAQgAJhYhBNUZeXTRD+fLJbwoiCLB0ImKMx/LBQJdnQjoAhsMBQkB4TOAAAoJ ECLB0ImKMx/LIyoH/jXT2J4T4eNcNPUeCfHMCvitWW+Zf8l4gCWnxYJL2nieguc68sPDBXuT 36gSzWSncz0g+UqRysV69zY9ZdcuZrcNWQuo5RKVXUDKGZ+2iRGvKc0k4Cce4w4cO6iMeL7N Rm6VtmJ60bUUpQboPEzaxns5cqgRmJTsr9YVfeptrr1e9U5xIROILu4tJpK6DMgwTNC3EsVI N9GiFy+Kb44ccz7wKhBXKZe0ghiZzlsjpEeY/aijW6I48kO7xiYFM7DWySXHP5nnK5Nf0k7p WH2pd0YlG9IRni4Lts2ILmvZHrHN1PT75GRmVMosMrSh4Zv+r15z3Zvar0aiyoojZd3u/tc=
  • Delivered-to: che-dev@xxxxxxxxxxx
  • List-archive: <https://www.eclipse.org/mailman/private/che-dev>
  • List-help: <mailto:che-dev-request@eclipse.org?subject=help>
  • List-subscribe: <https://www.eclipse.org/mailman/listinfo/che-dev>, <mailto:che-dev-request@eclipse.org?subject=subscribe>
  • List-unsubscribe: <https://www.eclipse.org/mailman/options/che-dev>, <mailto:che-dev-request@eclipse.org?subject=unsubscribe>
  • User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.1.1


On 07. 11. 19 10:06, Thomas Mäder wrote:
> Hi Lukas,
> 
> On 06/11/2019 15:16, Lukas Krejci wrote:
>> WDYT? Do you have some concerns about this idea?
> 
> Yes, I have some concerns: besides creating a "read-only" field in the
> devfile (which Mykola mentioned in his answer), I think it would violate
> containment: a devfile +/- creates a pod. A pod is container within a
> namespace. If we give the devfile control over things which live "up the
> hierarchy" from itself. 

If you specify a metadata.namespace field a pod YAML, it will be created
in the specified namespace.

> What happens if the user does not have a namespace with the name the devfile 
> requests?

As described in my email - if not specified, the namespace is determined
by the che server using the rules we already have in place. Namespace is
an optional field, as it is in k8s.


> A devfile should be reusable by multiple people across che installation.
> Since the namespaces depend on the configuration of the che instance, a
> devfile should not depend on a particular configuration. I think we
> should be wary of treating devfiles like stateful objects: devfiles are
> portable descriptions of workspaces, not the workspaces themselves. They
> are "constructors" if you will, not instances.
> 

I agree with that and I see a lot of good points in Mykola's email. But
at the same time I believe our goal is for the devfile to become a k8s
CR. At that point in time it IS going to have normal metadata section
like every other k8s object and that section WILL include the namespace,
because that is standard kubernetes.

The namespace is optional for exactly the reasons you describe.

> I am not familiar enough with our workspace engine to really pin this
> down, but I have a bad feeling about this. Maybe it helps if you explain
> the use cases we're trying to cover with this change.
> 

The idea came to our minds, because we are implementing "overrides" that
you could supply to a factory along with a url to a devfile. Factory
would then "materialize" the devfile and apply the overrides. At the
same time, we're adding the ability for the user to specify a namespace
where workspace should be created. It seemed logical and consistent with
Kubernetes to actually kinda "merge" these two features by having the
namespace in the devfile.

> /Thomas
> 

Attachment: signature.asc
Description: OpenPGP digital signature


Back to the top