Skip to content

Conversation

@aniskhalfallah
Copy link

@aniskhalfallah aniskhalfallah commented Nov 10, 2025

Summary :
Added ipsets information to supportbundle

Component:

  • pkg/support/dump_others.go
  • pkg/agent/util/ipset/ipset.go

Closes #7517

Signed-off-by: Anis KHALFALLAH <[email protected]>
return nil, fmt.Errorf("error saving ipset: %w, output: %s", err, string(output))
}
return output, nil
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

missing new line in the end.

return writeFile(d.fs, filepath.Join(basedir, "iptables"), "iptables", data)
}

func (d *agentDumper) dumpIPSets(basedir string) error {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you check and add unit tests for the new function?


ListEntries(name string) ([]string, error)

Save() ([]byte, error)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You need to update the mock code in pkg/agent/util/ipset/testing/mock_ipset.go since you added the method Save().

return writeFile(d.fs, filepath.Join(basedir, "iptables"), "iptables", data)
}

func (d *agentDumper) dumpIPSets(basedir string) error {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
func (d *agentDumper) dumpIPSets(basedir string) error {
func (d *agentDumper) dumpIPSet(basedir string) error {

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Include ipsets information in Agent supportbundle

3 participants