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
Actually, it is possible to use variable substitution on devfile, and the value of the variables comes from the devfile itself (from the .variables part).
It would be helpful to be able to pass values for variables from the CLI, without modifying the devfile.
For consistency, the same behaviour as the --env and --env-file options from docker could be used, by replacing env by var as these are not environment variables. For example:
$ odo dev --var CONTAINER_IMAGE=quay.io/myuser/myimage --var DEBUG=true --var USER
$ odo dev --var-file my-variables.var
$ cat my-variables.var
CONTAINER_IMAGE=quay.io/myuser/myimage
DEBUG=true
USER # this gets the value from the CLI current environment, if defined. If the env var is not defined, the variable is not overriden
AC:
for both odo dev and odo deploy commands
it should not modify devfile.yaml
Why is this needed?
It seems to be a common use case to create templates to be personalized at run time, similarly to how it is done with helm.
/kind feature
Which functionality do you think we should add?
Actually, it is possible to use variable substitution on devfile, and the value of the variables comes from the devfile itself (from the
.variables
part).It would be helpful to be able to pass values for variables from the CLI, without modifying the devfile.
For consistency, the same behaviour as the
--env
and--env-file
options fromdocker
could be used, by replacingenv
byvar
as these are not environment variables. For example:AC:
odo dev
andodo deploy
commandsWhy is this needed?
It seems to be a common use case to create templates to be personalized at run time, similarly to how it is done with helm.
Initial discussion: https://kubernetes.slack.com/archives/C01D6L2NUAG/p1645604581682759
The text was updated successfully, but these errors were encountered: