-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1234 from tejal29/fix_copy_from
Apply dockefile exclude only for first stage
- Loading branch information
Showing
3 changed files
with
14 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,11 @@ | ||
# This dockerfile makes sure the .dockerignore is working | ||
# If so then ignore/foo should copy to /foo | ||
# If not, then this image won't build because it will attempt to copy three files to /foo, which is a file not a directory | ||
FROM scratch | ||
FROM scratch as base | ||
COPY ignore/* /foo | ||
|
||
From base as first | ||
COPY --from=base /foo ignore/bar | ||
|
||
FROM first | ||
COPY --from=first ignore/* /fooAnother/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters