-
Notifications
You must be signed in to change notification settings - Fork 3
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 Dockerlint to the CI build #1247
Comments
Maybe I'm using it wrong, but
Now unless I'm very much mistaken, the At this point I'm not convinced it's going to be much help. |
In the fine tradition of linting programs everywhere (cough dialyzer cough), the error messages are...not particularly enlightening. However, both issues are potentially legitimate.
It is declared on line 53 but not defined. We define the The situation is roughly analogous to this C program: int main() {
int i;
return i;
} Any linter or compiler worth its salt should warn about the use of
It isn't warning about the command on line 12, it is warning about the comment on line 11. I assume the line number difference is due to how it is parsed. The reason for this warning is that a future version of Docker will return an error in that situation.
Or it used to, at least. I can't reproduce the warning with the version of Docker currently on my laptop. At any rate, removing the comments makes the message go away. |
Interestingly, someone has opened a ticket on the |
It's not really, though. The whole point of
Too bad if we wanted to document behaviour, I guess ;) |
I have no idea what he was even getting at there...the patch looks utterly unrelated. |
Are you sure about that?
It would be, if the user was required to supply it.
Indeed. I can't figure out why Docker would deprecate that behavior. The only thing I can figure is that they think you won't need it once |
No - I was (probably foolishly) basing it on the presumption that the docs here: https://docs.docker.com/engine/reference/builder/#arg were correct :) Edit: Whoops - totally misread those docs. Turns out they warn for the reverse case - the user specifying an argument that isn't in the file. Nevermind. |
No worries. The Docker docs can be voluminous but not especially helpful. |
It turns out that it was not complaining about the presence of the comment, but about the fact that there was no line continuation character at the end of the line. So, the documentation is fine; I didn't have to delete the comments. |
There is nothing to deploy here, so closing. |
Verify the Docker files using Dockerlint as part of the CI build.
https://github.com/RedCoolBeans/dockerlint
The text was updated successfully, but these errors were encountered: