summaryrefslogtreecommitdiff
path: root/libpod/container_log_linux.go
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2021-03-02 13:39:59 -0800
committerGitHub <noreply@github.com>2021-03-02 13:39:59 -0800
commit0a40c5a059455693de0cc9a3f4a2a16722fc61e9 (patch)
treee9c24fd97ce790027a4f9da0f2f186f5079f2625 /libpod/container_log_linux.go
parentb9181cf1ef255771a92a7258367826dbc3f1e091 (diff)
parentb19791c0b60b4f113d80e17a9ca9c7c2074be465 (diff)
downloadpodman-0a40c5a059455693de0cc9a3f4a2a16722fc61e9.tar.gz
podman-0a40c5a059455693de0cc9a3f4a2a16722fc61e9.tar.bz2
podman-0a40c5a059455693de0cc9a3f4a2a16722fc61e9.zip
Merge pull request #9477 from ashley-cui/journald
Tidy duplicate log tests
Diffstat (limited to 'libpod/container_log_linux.go')
-rw-r--r--libpod/container_log_linux.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/libpod/container_log_linux.go b/libpod/container_log_linux.go
index 5792633b0..4a541b6e7 100644
--- a/libpod/container_log_linux.go
+++ b/libpod/container_log_linux.go
@@ -52,6 +52,7 @@ func (c *Container) readFromJournal(ctx context.Context, options *logs.LogOption
if time.Now().Before(options.Since) {
return nil
}
+ // coreos/go-systemd/sdjournal expects a negative time.Duration for times in the past
config.Since = -time.Since(options.Since)
}
config.Matches = append(config.Matches, journal.Match{