diff --git a/internal/controller/provisioner/objects.go b/internal/controller/provisioner/objects.go index 14b3cbcc72..9ed081c219 100644 --- a/internal/controller/provisioner/objects.go +++ b/internal/controller/provisioner/objects.go @@ -1113,6 +1113,9 @@ func (p *NginxProvisioner) buildNginxPodTemplateSpec( func (p *NginxProvisioner) buildImage(nProxyCfg *graph.EffectiveNginxProxy) (string, corev1.PullPolicy) { image := defaultNginxImagePath + if p.cfg.Plus { + image = defaultNginxPlusImagePath + } tag := p.cfg.GatewayPodConfig.Version pullPolicy := defaultImagePullPolicy diff --git a/internal/controller/provisioner/objects_test.go b/internal/controller/provisioner/objects_test.go index 4af6f2deca..e72d1057c5 100644 --- a/internal/controller/provisioner/objects_test.go +++ b/internal/controller/provisioner/objects_test.go @@ -498,6 +498,7 @@ func TestBuildNginxResourceObjects_Plus(t *testing.T) { cfg: Config{ GatewayPodConfig: &config.GatewayPodConfig{ Namespace: ngfNamespace, + Version: "1.0.0", }, Plus: true, PlusUsageConfig: &config.UsageReportConfig{ @@ -611,6 +612,7 @@ func TestBuildNginxResourceObjects_Plus(t *testing.T) { Name: "nginx-plus-usage-certs", MountPath: "/etc/nginx/certs-bootstrap/", })) + g.Expect(container.Image).To(Equal(fmt.Sprintf("%s:1.0.0", defaultNginxPlusImagePath))) } func TestBuildNginxResourceObjects_DockerSecrets(t *testing.T) {