Skip to content

Ensure that ParsedDockerfile supports platform args#2780

Merged
rnorth merged 3 commits intomasterfrom
dockerfile-parse-args-2772
May 28, 2020
Merged

Ensure that ParsedDockerfile supports platform args#2780
rnorth merged 3 commits intomasterfrom
dockerfile-parse-args-2772

Conversation

@rnorth
Copy link
Copy Markdown
Member

@rnorth rnorth commented May 22, 2020

Fixes #2772

Also make parsing case insensitive, for better compliance with Dockerfile spec

Fixes #2772

Also make parsing case insensitive, for better compliance with Dockerfile spec
@rnorth rnorth requested review from bsideup and kiview as code owners May 22, 2020 11:58
@rnorth rnorth self-assigned this May 22, 2020

@Test
public void ignoringPlatformArgs() {
final ParsedDockerfile parsedDockerfile = new ParsedDockerfile(asList("FROM --platform=linux/amd64 someimage", "RUN something"));
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

since the parsing seem to support multiple flags, perhaps we should add this (2 or more flags) case too

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Platform seems to be the only arg that is supported by docker at present, but sure, seems like a good idea.

Copy link
Copy Markdown
Member

@bsideup bsideup left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good 👍

@rnorth rnorth added this to the next milestone May 28, 2020
@rnorth rnorth merged commit 3a2462c into master May 28, 2020
@rnorth rnorth deleted the dockerfile-parse-args-2772 branch May 28, 2020 22:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ParsedDockerfile's parsing of FROM lines doesn't handle arguments

2 participants