From 1cf5f2eb746b3aca819c2dea62f02d3b5891eea3 Mon Sep 17 00:00:00 2001 From: Ettore Di Giacinto Date: Tue, 26 Nov 2019 20:11:51 +0100 Subject: [PATCH] Enhance compile output --- pkg/compiler/compiler.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/pkg/compiler/compiler.go b/pkg/compiler/compiler.go index c34ab2b0..b682f067 100644 --- a/pkg/compiler/compiler.go +++ b/pkg/compiler/compiler.go @@ -156,6 +156,8 @@ func (cs *LuetCompiler) CompileParallel(concurrency int, keepPermissions bool, p } func (cs *LuetCompiler) compileWithImage(image, buildertaggedImage, packageImage string, concurrency int, keepPermissions bool, p CompilationSpec) (Artifact, error) { + pkgTag := ":package: " + p.GetPackage().GetName() + p.SetSeedImage(image) // In this case, we ignore the build deps as we suppose that the image has them - otherwise we recompose the tree with a solver, // and we build all the images first. keepImg := true @@ -185,6 +187,8 @@ func (cs *LuetCompiler) compileWithImage(image, buildertaggedImage, packageImage packageImage = "luet/" + p.GetPackage().GetFingerPrint() } + Info(pkgTag, "Generating :whale: definition") + // First we create the builder image p.WriteBuildImageDefinition(filepath.Join(buildDir, p.GetPackage().GetFingerPrint()+"-builder.dockerfile")) builderOpts := CompilerBackendOptions{ @@ -269,6 +273,8 @@ func (cs *LuetCompiler) compileWithImage(image, buildertaggedImage, packageImage artifact = NewPackageArtifact(p.Rel(p.GetPackage().GetFingerPrint() + ".package.tar")) artifact.SetCompileSpec(p) } else { + Info(pkgTag, "Generating delta") + artifact, err = ExtractArtifactFromDelta(rootfs, p.Rel(p.GetPackage().GetFingerPrint()+".package.tar"), diffs, concurrency, keepPermissions, p.GetIncludes()) if err != nil { return nil, errors.Wrap(err, "Could not generate deltas") @@ -280,6 +286,8 @@ func (cs *LuetCompiler) compileWithImage(image, buildertaggedImage, packageImage if err != nil { return artifact, err } + Info(pkgTag, " :white_check_mark: Done") + return artifact, nil }