From 337e7d88e66ca090a2e76301e0c3021e3c94f1c4 Mon Sep 17 00:00:00 2001 From: Rickard von Essen Date: Sun, 9 Jul 2017 21:50:20 +0200 Subject: [PATCH] post-processor/checksum: properly interpolate output Fix a bug where "output" of checksum post-processor was not correctly interpolating {{.BuilderType}}, {{.BuildName}}, and {{.ChecksumType}}. --- post-processor/checksum/post-processor.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/post-processor/checksum/post-processor.go b/post-processor/checksum/post-processor.go index 2ae6da164..70295c878 100644 --- a/post-processor/checksum/post-processor.go +++ b/post-processor/checksum/post-processor.go @@ -57,9 +57,10 @@ func getHash(t string) hash.Hash { func (p *PostProcessor) Configure(raws ...interface{}) error { err := config.Decode(&p.config, &config.DecodeOpts{ - Interpolate: true, + Interpolate: true, + InterpolateContext: &p.config.ctx, InterpolateFilter: &interpolate.RenderFilter{ - Exclude: []string{}, + Exclude: []string{"output"}, }, }, raws...) if err != nil {