Skip to content
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

Variables with default values don't work for image tags #188

Open
flcdrg opened this issue Apr 28, 2020 · 1 comment
Open

Variables with default values don't work for image tags #188

flcdrg opened this issue Apr 28, 2020 · 1 comment

Comments

@flcdrg
Copy link
Contributor

flcdrg commented Apr 28, 2020

Trying to use {env.VERSION:v1.0} (or anything else for the default value) results in an error.

[ERROR] failed to load config from "dobi.yaml": Error at myimage.tags: failed validation: the first tag "v1.0}" may not include an image name

I'm guessing it's trying to validate the tag before the variable is evaluated.

@dnephin
Copy link
Owner

dnephin commented May 6, 2020

Thank you for the bug report!

One way to fix this might be to have ValidateTags create a call something like this https://github.com/dnephin/dobi/blob/master/execenv/environment.go#L45-L51 on the tag value, before parsing it, to remove the template.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants