diff --git a/hack/install-gitlab.sh b/hack/install-gitlab.sh index 5f68705046..c99085f5fd 100755 --- a/hack/install-gitlab.sh +++ b/hack/install-gitlab.sh @@ -73,7 +73,6 @@ spec: gitlab_rails['gitlab_shell_ssh_port'] = 30022 gitlab_rails['gitlab_email_enabled'] = false puma['worker_processes'] = 0 - sidekiq['max_concurrency'] = 1 prometheus_monitoring['enable'] = false gitlab_rails['env'] = { 'MALLOC_CONF' => 'dirty_decay_ms:1000,muzzy_decay_ms:1000' diff --git a/pkg/pipelines/tekton/gitlab_test.go b/pkg/pipelines/tekton/gitlab_test.go index 2a4e14eb62..45756a8c1e 100644 --- a/pkg/pipelines/tekton/gitlab_test.go +++ b/pkg/pipelines/tekton/gitlab_test.go @@ -44,10 +44,6 @@ import ( ) func TestGitlab(t *testing.T) { - // this test is unreliable and fails majority of the time with unrelated problem - // skip this for now until the issue is fixed - // https://github.com/knative/func/issues/2185 - t.Skip() var err error ctx, cancel := signal.NotifyContext(context.Background(), os.Interrupt) defer cancel() @@ -238,7 +234,8 @@ func setupGitlabEnv(ctx context.Context, t *testing.T, baseURL, username, passwo } _, _, err = glabCli.Settings.UpdateSettings(newSettings) if err != nil { - t.Fatal(err) + // just log the error, it appears that despite the error the setting is updated + t.Log(err) } // For some reason the setting update does not kick in immediately. diff --git a/pkg/pipelines/tekton/pac/client.go b/pkg/pipelines/tekton/pac/client.go index 863cb14ad3..64687d8c17 100644 --- a/pkg/pipelines/tekton/pac/client.go +++ b/pkg/pipelines/tekton/pac/client.go @@ -11,7 +11,7 @@ import ( // NewTektonPacClientAndResolvedNamespace returns PipelinesascodeV1alpha1Client,namespace,error func NewTektonPacClientAndResolvedNamespace(namespace string) (*pacv1alpha1.PipelinesascodeV1alpha1Client, string, error) { var err error - if namespace != "" { + if namespace == "" { namespace, err = k8s.GetDefaultNamespace() if err != nil { return nil, "", err diff --git a/pkg/pipelines/tekton/templates.go b/pkg/pipelines/tekton/templates.go index ee6ff7f8b2..71f193fbf2 100644 --- a/pkg/pipelines/tekton/templates.go +++ b/pkg/pipelines/tekton/templates.go @@ -204,12 +204,17 @@ func createPipelineRunTemplatePAC(f fn.Function, labels map[string]string) error s2iImageScriptsUrl = quarkusS2iImageScriptsUrl } + image := f.Deploy.Image + if image == "" { + image = f.Image + } + data := templateData{ FunctionName: f.Name, Annotations: f.Deploy.Annotations, Labels: labels, ContextDir: contextDir, - FunctionImage: f.Deploy.Image, + FunctionImage: image, Registry: f.Registry, BuilderImage: getBuilderImage(f), BuildEnvs: buildEnvs, @@ -230,8 +235,8 @@ func createPipelineRunTemplatePAC(f fn.Function, labels map[string]string) error S2iImageScriptsUrl: s2iImageScriptsUrl, - RepoUrl: "{{ repo_url }}", - Revision: "{{ revision }}", + RepoUrl: "\"{{ repo_url }}\"", + Revision: "\"{{ revision }}\"", } var template string