You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by nf...@apache.org on 2019/09/23 16:33:00 UTC
[camel-k] branch master updated: fix(builder): Clean ReplaceHost
step leftover that causes nil pointer dereference panic
This is an automated email from the ASF dual-hosted git repository.
nferraro pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/camel-k.git
The following commit(s) were added to refs/heads/master by this push:
new c76132d fix(builder): Clean ReplaceHost step leftover that causes nil pointer dereference panic
c76132d is described below
commit c76132d6e56a0e369bd73c9bd9b5f569fb520527
Author: Antonin Stefanutti <an...@stefanutti.fr>
AuthorDate: Mon Sep 23 11:07:57 2019 +0200
fix(builder): Clean ReplaceHost step leftover that causes nil pointer dereference panic
---
pkg/builder/s2i/s2i.go | 3 +--
pkg/trait/builder.go | 3 ---
2 files changed, 1 insertion(+), 5 deletions(-)
diff --git a/pkg/builder/s2i/s2i.go b/pkg/builder/s2i/s2i.go
index 45629a7..b1a3bd8 100644
--- a/pkg/builder/s2i/s2i.go
+++ b/pkg/builder/s2i/s2i.go
@@ -26,8 +26,7 @@ func init() {
}
type steps struct {
- Publisher builder.Step
- ReplaceHost builder.Step
+ Publisher builder.Step
}
// Steps --
diff --git a/pkg/trait/builder.go b/pkg/trait/builder.go
index e0856a2..7b167ff 100644
--- a/pkg/trait/builder.go
+++ b/pkg/trait/builder.go
@@ -46,9 +46,6 @@ func (t *builderTrait) Configure(e *Environment) (bool, error) {
func (t *builderTrait) Apply(e *Environment) error {
if platform.SupportsS2iPublishStrategy(e.Platform) {
e.Steps = s2i.DefaultSteps
- if e.DetermineProfile() == v1alpha1.TraitProfileKnative {
- e.Steps = append(e.Steps, s2i.Steps.ReplaceHost)
- }
} else if platform.SupportsKanikoPublishStrategy(e.Platform) {
e.Steps = kaniko.DefaultSteps
e.BuildDir = kaniko.BuildDir