mirror of
https://github.com/ClusterCockpit/cc-backend
synced 2025-07-01 03:03:50 +02:00
Enclose terms by spaces in app detection
This commit is contained in:
parent
dca25cc601
commit
8378784231
@ -111,7 +111,7 @@ func (t *AppTagger) Match(job *schema.Job) {
|
||||
for _, a := range t.apps {
|
||||
tag := a.tag
|
||||
for _, s := range a.strings {
|
||||
if strings.Contains(strings.ToLower(jobscript), s) {
|
||||
if strings.Contains(strings.ToLower(jobscript), fmt.Sprintf(" %s ", s)) {
|
||||
if !r.HasTag(id, t.tagType, tag) {
|
||||
r.AddTagOrCreateDirect(id, t.tagType, tag)
|
||||
break out
|
||||
|
Loading…
x
Reference in New Issue
Block a user