Skip to content

envsubst on certain skaffold fields #75

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

Closed
r2d4 opened this issue Feb 12, 2018 · 3 comments
Closed

envsubst on certain skaffold fields #75

r2d4 opened this issue Feb 12, 2018 · 3 comments

Comments

@r2d4
Copy link
Contributor

r2d4 commented Feb 12, 2018

Do we want to expand bash substitutions in some skaffold fields? It is a bit of feature creep, but might be useful for complete portability of skaffold.yaml

We could ship examples for other repos by including a workspace: $GOPATH/src/path/to/project, so that we don't need to keep all of the example code here, only the example configuration.

It also makes paths less fragile, since its not so dependent on where the user actually runs skaffold run.

Here's a library we could use (note: haven't used it before, this is just the result of a quick google search)
https://github.com/drone/envsubst

@dlorenc
Copy link
Contributor

dlorenc commented Feb 12, 2018

Hmm, do you have any more examples on what this would be used for? envsubst is a small step away from full templating and adds a lot of complexity.

@r2d4
Copy link
Contributor Author

r2d4 commented Feb 12, 2018

The main issue is that each skaffold.yaml has a specific location that it must be run in.

In the example config
workspace: examples/getting-started

This won't work anywhere other than the root directory.

If you do workspace: ., it won't work anywhere other than examples/getting-started. I'm sure there are more ambiguous situations too.

Of course, you can make it an absolute path, but that won't work when you're sharing the config with others.

I'm on the fence about this one, I really don't think that envsubst is a good solution, but I'd like to make the config paths as unambiguous as possible, especially to help with automation.

@r2d4 r2d4 added the kind/question User question label Feb 12, 2018
@r2d4
Copy link
Contributor Author

r2d4 commented Mar 1, 2018

Closing this. Not pursuing

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