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

Dockerfile linting error in FROM #269

Closed
rodynnz opened this issue May 22, 2018 · 5 comments
Closed

Dockerfile linting error in FROM #269

rodynnz opened this issue May 22, 2018 · 5 comments

Comments

@rodynnz
Copy link

rodynnz commented May 22, 2018

If your FROM contains a port in the registry host section, the linting throws an error in the tag section.

Example to reproduce:

FROM example.registry.com:12345/base/image:1.0.0

Error shown:

[dockerfile-utils] Invalid reference format

Versions affected:

  • Visual Studio Code 1.23.1 (April 2018)
  • Docker 0.0.27
@rcjsuen
Copy link
Contributor

rcjsuen commented May 22, 2018

Hi, @rodynnz. Thank you for your bug report. I identified this error a few days ago and have already opened rcjsuen/dockerfile-utils#39.

Regarding private registries, is the lack of a port number also valid? Will the Docker Engine query a default port with the registry API?

# is this Dockerfile valid?
FROM example.registry.com/base/image:1.0.0

@rodynnz
Copy link
Author

rodynnz commented May 22, 2018

Yeah sure, port is optional and follow the rules for HTTP/S connections (ports 80 or 443 are default ones)

@rcjsuen
Copy link
Contributor

rcjsuen commented May 22, 2018

@rodynnz Cool, thanks for the info! I'll look into correcting my parser... :)

@StephenWeatherford
Copy link
Contributor

@rodynnz This has been fixed and will be available in the next release.

@StephenWeatherford
Copy link
Contributor

@rodynnz Just wanted to let you know that we have published a new version of the Docker extension that should contain this fix. Happy coding!

@vscodebot vscodebot bot locked and limited conversation to collaborators Feb 18, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants