@@ -50,7 +50,7 @@ func init() {
5050 dockerBuildCmd .Flags ().StringVar (& dco .BuildArgs .TargetArch , "targetarch" , "" , "target arch to build" )
5151 dockerBuildCmd .Flags ().StringVar (& dco .BuildArgs .CommitSHA , "commitsha" , "" , "build arg commit sha to add to build" )
5252 dockerBuildCmd .Flags ().StringVar (& dco .BuildArgs .BuildId , "build-id" , "" , "build id to add to container metadata" )
53- dockerBuildCmd .Flags ().StringVar (& dco .DockerFile , "dockerfile" , "" , "dockerfile of image to build" )
53+ dockerBuildCmd .Flags ().StringVar (& dco .Dockerfile , "dockerfile" , "Dockerfile " , "dockerfile of image to build" )
5454 dockerBuildCmd .Flags ().StringVar (& dco .Image .Name , "name" , "" , "container image name registry/name:tag@digest" )
5555 dockerBuildCmd .Flags ().StringVar (& dco .Image .Registry , "registry" , Registry , "Registry to tag image and push container registry/name:tag@digest" )
5656 dockerBuildCmd .Flags ().StringVar (& dco .Image .Tag , "tag" , "" , "container tag registry/name:tag@digest" )
@@ -81,7 +81,7 @@ type dockerBuildOpts struct {
8181 PlatformFlag string
8282 Platform []string
8383 BuildArgs BuildArgs
84- DockerFile string
84+ Dockerfile string
8585 Image Image
8686 Path string
8787}
@@ -136,6 +136,7 @@ func dockerBuild() error {
136136 "--build-arg" , "TARGETARCH=" + dco .BuildArgs .TargetArch ,
137137 "--build-arg" , "COMMIT_SHA=" + dco .BuildArgs .CommitSHA ,
138138 "--build-arg" , "BUILD_ID=" + dco .BuildArgs .BuildId ,
139+ "-f" , dco .Path + dco .Dockerfile ,
139140 dco .Path ).Run ()
140141
141142 return nil
0 commit comments