Changement dans l'URL, \\ to / car non accepté par linux

This commit is contained in:
Benjamin 2022-03-19 18:16:57 +01:00
parent cd68ba52b9
commit c9f317f931
2 changed files with 3 additions and 4 deletions

View File

@ -43,8 +43,7 @@ func (rule EraseFileRule) Execute(data string) (*protocol.ProtocolWriterResult,
if rule.Match(data) { if rule.Match(data) {
values := rule.matcher.Parse(data) values := rule.matcher.Parse(data)
//errRemoveFile := os.Remove(fmt.Sprintf("%s/%s", rule.storagePath, values[1])) hasRemoveFile := utils.DeleteFile(fmt.Sprintf("%s/%s", rule.storagePath, values[1]), 10)
hasRemoveFile := utils.DeleteFile(fmt.Sprintf("%s\\%s", rule.storagePath, values[1]), 10)
if !hasRemoveFile { if !hasRemoveFile {
return rule.protocolRepo.ExecuteWriter(writers.EraseErrorRulePrefix), nil return rule.protocolRepo.ExecuteWriter(writers.EraseErrorRulePrefix), nil
} }

View File

@ -1,8 +1,8 @@
{ {
"multicastNetworkInterface" : "Loopback Pseudo-Interface 1", "multicastNetworkInterface" : "wlp1s0",
"multicastAddress" : "224.66.66.1:15502", "multicastAddress" : "224.66.66.1:15502",
"multicastSecond" : 30, "multicastSecond" : 30,
"domain" : "lightcontainerSB01", "domain" : "lightcontainerSB01",
"unicastPort" : 58000, "unicastPort" : 58000,
"storagePath" : "C:\\Users\\ledou\\Documents\\sbe" "storagePath" : "/home/benjamin/sbe"
} }