upload: append container name in case of merged journal

This commit is contained in:
Christophe Siraut 2020-10-30 13:29:21 +01:00
parent e7ba3d4b72
commit b0e7fface4
1 changed files with 3 additions and 0 deletions

View File

@ -123,6 +123,9 @@ def UploadView(request, debug=False):
timestamp = datetime.datetime.fromtimestamp(int(data['__REALTIME_TIMESTAMP']) / 1000000)
if (now - timestamp).days > settings.LOGTRACKER_HISTORY:
continue
hostname = data.get('_HOSTNAME')
if hostname not in request.host_verified:
request.host_verified += "_%s" % hostname
entry = Entry(timestamp=timestamp, host=request.host_verified, data=data)
new_entries.append(entry)
count += 1