-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Add support for template_driver
in composefiles
#1100
Conversation
505668f
to
871eb2e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SGTM but it definitely needs some tests 😄
871eb2e
to
87f81d1
Compare
e7957c3
to
17a83b9
Compare
@silvin-lubecki added some test |
Linting failure;
|
This maps the `--template-driver` flag on secret and config creation. Signed-off-by: Vincent Demeester <vincent@sbr.pm>
17a83b9
to
c313e7b
Compare
}, | ||
}, | ||
} | ||
assert.DeepEqual(t, config, expected, cmpopts.EquateEmpty()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can simplify the test:
assert.Assert(t, is.Equal(config.Configs["config"].TemplateDriver, "config-driver"))
assert.Assert(t, is.Equal(config.Secrets["secret"].TemplateDriver, "secret-driver"))
Will this be included in 18.09 release? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Not sure if this can still make it into 18.09. If it doesn't, this change needs to be moved to a 3.8 schema for the compose file.
Is there another driver other than the built-in go one? |
Good point; don't think there's another driver yet; otoh, isn't it required to set a driver in order to use templating? (will have to check) |
To come back to my previous comment;
So, yes, we need this option to enable templating, otherwise no templating will be applied. I see this needs a rebase though (and would now have to be moved to docker-compose schema 3.8 |
Carried in #1746 |
Thanks @thaJeztah 😽 |
This maps the
--template-driver
flag on secret and config creation.See #896 (and upstream moby/moby#33702)
Signed-off-by: Vincent Demeester vincent@sbr.pm