From a7895826be378da83a27d0b43eacacdc6af055f5 Mon Sep 17 00:00:00 2001 From: chanwook lee <80809874+clee94713@users.noreply.github.com> Date: Tue, 6 Dec 2022 16:32:18 +0900 Subject: [PATCH] [fix] modify func matchString in dispatcher (#398) * [fix] modify func matchString in dispatcher * [fix] modify func matchString in dispatcher --- Makefile | 2 +- config/release.yaml | 8 ++++---- pkg/dispatcher/dispatcher.go | 7 +------ 3 files changed, 6 insertions(+), 11 deletions(-) diff --git a/Makefile b/Makefile index 59f300a..916bdca 100644 --- a/Makefile +++ b/Makefile @@ -1,5 +1,5 @@ # Current Operator version -VERSION ?= v0.6.0 +VERSION ?= v0.6.1 REGISTRY ?= tmaxcloudck # Image URL to use all building/pushing image targets diff --git a/config/release.yaml b/config/release.yaml index 69ffbc5..a2c800c 100644 --- a/config/release.yaml +++ b/config/release.yaml @@ -84,7 +84,7 @@ spec: containers: - command: - /controller - image: docker.io/tmaxcloudck/cicd-operator:v0.6.0 + image: docker.io/tmaxcloudck/cicd-operator:v0.6.1 imagePullPolicy: Always name: manager env: @@ -171,7 +171,7 @@ spec: containers: - command: - /blocker - image: docker.io/tmaxcloudck/cicd-blocker:v0.6.0 + image: docker.io/tmaxcloudck/cicd-blocker:v0.6.1 imagePullPolicy: Always name: manager resources: @@ -231,7 +231,7 @@ spec: containers: - command: - /webhook - image: docker.io/tmaxcloudck/cicd-webhook:v0.6.0 + image: docker.io/tmaxcloudck/cicd-webhook:v0.6.1 imagePullPolicy: Always name: manager resources: @@ -291,7 +291,7 @@ spec: containers: - command: - /apiserver - image: docker.io/tmaxcloudck/cicd-api-server:v0.6.0 + image: docker.io/tmaxcloudck/cicd-api-server:v0.6.1 imagePullPolicy: Always name: manager resources: diff --git a/pkg/dispatcher/dispatcher.go b/pkg/dispatcher/dispatcher.go index 2812719..2df024a 100644 --- a/pkg/dispatcher/dispatcher.go +++ b/pkg/dispatcher/dispatcher.go @@ -19,7 +19,6 @@ package dispatcher import ( "context" "fmt" - "regexp" "strings" cicdv1 "github.com/tmax-cloud/cicd-operator/api/v1" @@ -363,9 +362,5 @@ func applyNotification(jobs []cicdv1.Job, noti *cicdv1.Notification) []cicdv1.Jo } func matchString(incoming, target string) bool { - re, err := regexp.Compile(target) - if err != nil { - return false - } - return re.MatchString(incoming) + return incoming == target }