Skip to content

Commit

Permalink
Merge pull request #298 from kierendavies/podman-rename-id-field
Browse files Browse the repository at this point in the history
Look for `Id` field instead of `id` when deserializing stats
  • Loading branch information
fussybeaver authored Mar 21, 2023
2 parents 44ce77c + 84f5c26 commit a2bf891
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/container.rs
Original file line number Diff line number Diff line change
Expand Up @@ -772,6 +772,9 @@ pub struct Stats {
pub precpu_stats: CPUStats,
pub storage_stats: StorageStats,
pub name: String,

// Podman incorrectly capitalises the "id" field. See https://github.com/containers/podman/issues/17869
#[serde(alias = "Id")]
pub id: String,
}

Expand Down

0 comments on commit a2bf891

Please sign in to comment.