add warning for template option#390
Conversation
|
ping @opencontainers/runtime-tools-maintainers |
| **--template**=PATH | ||
| Override the default template with your own. | ||
| Additional options will only adjust the relevant portions of your template. | ||
| whether template is valid or not will not be checked, this may lead to finally generated config file can't work directly. Currently, users should guarantee template is valid themselves. |
There was a problem hiding this comment.
what do you mean by can't work directly?
There was a problem hiding this comment.
For example, as we don't have template validation now, if there are duplicated namespace entries in user's template, the final config file will also have duplicated namespace. Then the config file is invalid and can't be used directly.
We need to solve such problems, but not easy, should reform and reuse validate fucntions, currently adding warning will be better.
There was a problem hiding this comment.
@Mashimiao Thanks! Maybe word this as
"Templates are not validated for correctness, so the user should ensure that they are correct."
Signed-off-by: Ma Shimiao <mashimiao.fnst@cn.fujitsu.com>
|
@opencontainers/runtime-tools-maintainers PTAL |
|
@Mashimiao I think we should add 'template validation' . |
|
We can add that in a follow-on I think. LGTM. |
|
@liangchenye If we want to add 'template validation', we need to make some modifications on Generation and validaiton. I think we can't finish them in short period, so I submitted this PR to give a warn to users. |
|
OK, I add an issue to keep track of this. #403 |
Signed-off-by: Ma Shimiao mashimiao.fnst@cn.fujitsu.com