Skip to content

Commit

Permalink
Add dependentProjects to v1alpha1 spec as well and update conversion
Browse files Browse the repository at this point in the history
Signed-off-by: Angel Misevski <amisevsk@redhat.com>
  • Loading branch information
amisevsk committed Aug 8, 2023
1 parent 5a87bde commit 5d26e51
Show file tree
Hide file tree
Showing 7 changed files with 511 additions and 0 deletions.
124 changes: 124 additions & 0 deletions crds/workspace.devfile.io_devworkspaces.v1beta1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1743,6 +1743,130 @@ spec:
type: object
type: object
type: array
dependentProjects:
description: Additional projects related to the main project in
the devfile, contianing names and sources locations
items:
oneOf:
- required:
- git
- required:
- github
- required:
- zip
- required:
- custom
properties:
clonePath:
description: Path relative to the root of the projects to
which this project should be cloned into. This is a unix-style
relative path (i.e. uses forward slashes). The path is
invalid if it is absolute or tries to escape the project
root through the usage of '..'. If not specified, defaults
to the project name.
type: string
custom:
description: Project's Custom source
properties:
embeddedResource:
type: object
x-kubernetes-embedded-resource: true
x-kubernetes-preserve-unknown-fields: true
projectSourceClass:
type: string
required:
- embeddedResource
- projectSourceClass
type: object
git:
description: Project's Git source
properties:
checkoutFrom:
description: Defines from what the project should be
checked out. Required if there are more than one remote
configured
properties:
remote:
description: The remote name should be used as init.
Required if there are more than one remote configured
type: string
revision:
description: The revision to checkout from. Should
be branch name, tag or commit id. Default branch
is used if missing or specified revision is not
found.
type: string
type: object
remotes:
additionalProperties:
type: string
description: The remotes map which should be initialized
in the git project. Must have at least one remote
configured
type: object
sparseCheckoutDir:
description: Part of project to populate in the working
directory.
type: string
type: object
github:
description: Project's GitHub source
properties:
checkoutFrom:
description: Defines from what the project should be
checked out. Required if there are more than one remote
configured
properties:
remote:
description: The remote name should be used as init.
Required if there are more than one remote configured
type: string
revision:
description: The revision to checkout from. Should
be branch name, tag or commit id. Default branch
is used if missing or specified revision is not
found.
type: string
type: object
remotes:
additionalProperties:
type: string
description: The remotes map which should be initialized
in the git project. Must have at least one remote
configured
type: object
sparseCheckoutDir:
description: Part of project to populate in the working
directory.
type: string
type: object
name:
description: Project name
type: string
sourceType:
description: Type of project source
enum:
- Git
- Github
- Zip
- Custom
type: string
zip:
description: Project's Zip source
properties:
location:
description: Zip project's source location address.
Should be file path of the archive, e.g. file://$FILE_PATH
type: string
sparseCheckoutDir:
description: Part of project to populate in the working
directory.
type: string
type: object
required:
- name
type: object
type: array
events:
description: Bindings of commands to events. Each command is referred-to
by its name.
Expand Down
124 changes: 124 additions & 0 deletions crds/workspace.devfile.io_devworkspaces.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1739,6 +1739,130 @@ spec:
type: object
type: object
type: array
dependentProjects:
description: Additional projects related to the main project in
the devfile, contianing names and sources locations
items:
oneOf:
- required:
- git
- required:
- github
- required:
- zip
- required:
- custom
properties:
clonePath:
description: Path relative to the root of the projects to
which this project should be cloned into. This is a unix-style
relative path (i.e. uses forward slashes). The path is
invalid if it is absolute or tries to escape the project
root through the usage of '..'. If not specified, defaults
to the project name.
type: string
custom:
description: Project's Custom source
properties:
embeddedResource:
type: object
x-kubernetes-embedded-resource: true
x-kubernetes-preserve-unknown-fields: true
projectSourceClass:
type: string
required:
- embeddedResource
- projectSourceClass
type: object
git:
description: Project's Git source
properties:
checkoutFrom:
description: Defines from what the project should be
checked out. Required if there are more than one remote
configured
properties:
remote:
description: The remote name should be used as init.
Required if there are more than one remote configured
type: string
revision:
description: The revision to checkout from. Should
be branch name, tag or commit id. Default branch
is used if missing or specified revision is not
found.
type: string
type: object
remotes:
additionalProperties:
type: string
description: The remotes map which should be initialized
in the git project. Must have at least one remote
configured
type: object
sparseCheckoutDir:
description: Part of project to populate in the working
directory.
type: string
type: object
github:
description: Project's GitHub source
properties:
checkoutFrom:
description: Defines from what the project should be
checked out. Required if there are more than one remote
configured
properties:
remote:
description: The remote name should be used as init.
Required if there are more than one remote configured
type: string
revision:
description: The revision to checkout from. Should
be branch name, tag or commit id. Default branch
is used if missing or specified revision is not
found.
type: string
type: object
remotes:
additionalProperties:
type: string
description: The remotes map which should be initialized
in the git project. Must have at least one remote
configured
type: object
sparseCheckoutDir:
description: Part of project to populate in the working
directory.
type: string
type: object
name:
description: Project name
type: string
sourceType:
description: Type of project source
enum:
- Git
- Github
- Zip
- Custom
type: string
zip:
description: Project's Zip source
properties:
location:
description: Zip project's source location address.
Should be file path of the archive, e.g. file://$FILE_PATH
type: string
sparseCheckoutDir:
description: Part of project to populate in the working
directory.
type: string
type: object
required:
- name
type: object
type: array
events:
description: Bindings of commands to events. Each command is referred-to
by its name.
Expand Down
117 changes: 117 additions & 0 deletions crds/workspace.devfile.io_devworkspacetemplates.v1beta1.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -1671,6 +1671,123 @@ spec:
type: object
type: object
type: array
dependentProjects:
description: Additional projects related to the main project in the
devfile, contianing names and sources locations
items:
oneOf:
- required:
- git
- required:
- github
- required:
- zip
- required:
- custom
properties:
clonePath:
description: Path relative to the root of the projects to which
this project should be cloned into. This is a unix-style relative
path (i.e. uses forward slashes). The path is invalid if it
is absolute or tries to escape the project root through the
usage of '..'. If not specified, defaults to the project name.
type: string
custom:
description: Project's Custom source
properties:
embeddedResource:
type: object
x-kubernetes-embedded-resource: true
x-kubernetes-preserve-unknown-fields: true
projectSourceClass:
type: string
required:
- embeddedResource
- projectSourceClass
type: object
git:
description: Project's Git source
properties:
checkoutFrom:
description: Defines from what the project should be checked
out. Required if there are more than one remote configured
properties:
remote:
description: The remote name should be used as init.
Required if there are more than one remote configured
type: string
revision:
description: The revision to checkout from. Should be
branch name, tag or commit id. Default branch is used
if missing or specified revision is not found.
type: string
type: object
remotes:
additionalProperties:
type: string
description: The remotes map which should be initialized
in the git project. Must have at least one remote configured
type: object
sparseCheckoutDir:
description: Part of project to populate in the working
directory.
type: string
type: object
github:
description: Project's GitHub source
properties:
checkoutFrom:
description: Defines from what the project should be checked
out. Required if there are more than one remote configured
properties:
remote:
description: The remote name should be used as init.
Required if there are more than one remote configured
type: string
revision:
description: The revision to checkout from. Should be
branch name, tag or commit id. Default branch is used
if missing or specified revision is not found.
type: string
type: object
remotes:
additionalProperties:
type: string
description: The remotes map which should be initialized
in the git project. Must have at least one remote configured
type: object
sparseCheckoutDir:
description: Part of project to populate in the working
directory.
type: string
type: object
name:
description: Project name
type: string
sourceType:
description: Type of project source
enum:
- Git
- Github
- Zip
- Custom
type: string
zip:
description: Project's Zip source
properties:
location:
description: Zip project's source location address. Should
be file path of the archive, e.g. file://$FILE_PATH
type: string
sparseCheckoutDir:
description: Part of project to populate in the working
directory.
type: string
type: object
required:
- name
type: object
type: array
events:
description: Bindings of commands to events. Each command is referred-to
by its name.
Expand Down
Loading

0 comments on commit 5d26e51

Please sign in to comment.