Skip to content
This repository was archived by the owner on Mar 27, 2024. It is now read-only.

do not diff image sha or hostname in metadata #234

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions differs/metadata_diff.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,6 @@ func getMetadataList(image pkgutil.Image) ([]string, error) {
}
c := configFile.Config
return []string{
fmt.Sprintf("Hostname: %s", c.Hostname),
fmt.Sprintf("Domainname: %s", c.Domainname),
fmt.Sprintf("User: %s", c.User),
fmt.Sprintf("AttachStdin: %t", c.AttachStdin),
Expand All @@ -93,7 +92,6 @@ func getMetadataList(image pkgutil.Image) ([]string, error) {
fmt.Sprintf("Env: %s", strings.Join(c.Env, ",")),
fmt.Sprintf("Cmd: %s", strings.Join(c.Cmd, ",")),
fmt.Sprintf("ArgsEscaped: %t", c.ArgsEscaped),
fmt.Sprintf("Image: %s", c.Image),
fmt.Sprintf("Volumes: %v", pkgutil.SortMap(c.Volumes)),
fmt.Sprintf("Workdir: %s", c.WorkingDir),
fmt.Sprintf("Entrypoint: %s", strings.Join(c.Entrypoint, ",")),
Expand Down
4 changes: 1 addition & 3 deletions tests/metadata_diff_expected.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,14 +6,12 @@
"Diff": {
"Adds": [
"ExposedPorts: 1234/tcp:{}",
"Image: sha256:0b30c570b95ba9cc450c8252cb264a8c66f7492a7dd6fb32f356267b9e04038f",
"Entrypoint: /entrypoint"
],
"Dels": [
"ExposedPorts: 1234/tcp:{} 4321/tcp:{}",
"Image: sha256:63d847f046cdda00df8ba9176753059439478784129443dd1da632504dce95bb",
"Entrypoint: "
]
}
}
]
]