From 6b7bebde29f222670fae844abbc0d1ed03f4e723 Mon Sep 17 00:00:00 2001 From: Johnny Jazeix Date: Fri, 29 Oct 2021 17:43:08 +0200 Subject: [PATCH] allow use of host:port in a FROM instruction fixes: https://github.com/hadolint/hadolint/issues/355 --- src/Language/Docker/Parser/From.hs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/Language/Docker/Parser/From.hs b/src/Language/Docker/Parser/From.hs index 1e14de1..13d1869 100644 --- a/src/Language/Docker/Parser/From.hs +++ b/src/Language/Docker/Parser/From.hs @@ -9,11 +9,9 @@ import Language.Docker.Syntax parseRegistry :: (?esc :: Char) => Parser Registry parseRegistry = do - domain <- someUnless "a domain name" (== '.') - void $ char '.' - tld <- someUnless "a TLD" (== '/') + registry <- someUnless "a registry" (== '/') void $ char '/' - return $ Registry (domain <> "." <> tld) + return $ Registry (registry) parsePlatform :: (?esc :: Char) => Parser Platform parsePlatform = do