mirror of
https://github.com/GoogleContainerTools/kaniko
synced 2026-10-22 10:38:44 +02:00
adding reproducible flag (#205)
* adding reproducible test * newer version of go-containerregistry * new ImageOptions * switch reproducible flag to default to false * small fixes * update dep
This commit is contained in:
@@ -41,6 +41,7 @@ var (
|
||||
buildArgs multiArg
|
||||
tarPath string
|
||||
singleSnapshot bool
|
||||
reproducible bool
|
||||
)
|
||||
|
||||
func init() {
|
||||
@@ -56,6 +57,7 @@ func init() {
|
||||
RootCmd.PersistentFlags().BoolVarP(&force, "force", "", false, "Force building outside of a container")
|
||||
RootCmd.PersistentFlags().StringVarP(&tarPath, "tarPath", "", "", "Path to save the image in as a tarball instead of pushing")
|
||||
RootCmd.PersistentFlags().BoolVarP(&singleSnapshot, "single-snapshot", "", false, "Set this flag to take a single snapshot at the end of the build.")
|
||||
RootCmd.PersistentFlags().BoolVarP(&reproducible, "reproducible", "", false, "Strip timestamps out of the image to make it reproducible")
|
||||
}
|
||||
|
||||
var RootCmd = &cobra.Command{
|
||||
@@ -87,6 +89,7 @@ var RootCmd = &cobra.Command{
|
||||
SnapshotMode: snapshotMode,
|
||||
Args: buildArgs,
|
||||
SingleSnapshot: singleSnapshot,
|
||||
Reproducible: reproducible,
|
||||
})
|
||||
if err != nil {
|
||||
logrus.Error(err)
|
||||
|
||||
Reference in New Issue
Block a user