UI: search and filter containers by port number in search bar (⌘K)

Open Beginner friendly
#289 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
76/100
Issue type
Feature
Clarity
Clearly specified
Activity status
Active
Tech stack
docker, rust
Domain
frontend

Research direction

Start in the container list definition under crates/kiri/src/ui/ and read how its hit matcher searches container names and images. Extend port matching to include public and private values from c.Ports, then verify that searching for a displayed port finds the corresponding container.

Written by the indexing model from the issue text.

Description

What you're trying to do

When running multiple containers or Compose stacks, I frequently need to find which container is publishing or listening on a specific port (e.g. "which container is using port 3306 or 8080?").

Currently, the global search filter in the UI (⌘K / ⌘F / Ctrl+K) only matches container names and images. Typing a port number yields no matches, even though the Ports column shows them. I currently have to drop to the terminal or manually scan the list.

What you'd like Kiri to do

Allow the search bar to also match container ports (public and private ports from c.Ports).

In the UI container list definition (crates/kiri/src/ui/):

containers: {
  hit: (c) => match(
    c.Names[0],
    c.Image,
    ...(c.Ports || []).flatMap((p) => [p.PublicPort, p.PrivatePort])
  )
}

Including port numbers in the hit matcher would allow quick filtering by port numbers in the main window.

Would you like to build it?

No, just suggesting it

Dominant language
Rust
Stars
7.5k
Forks
329
Avg merge
7h 48m
Merged PRs (30d)
105

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from libracoder/kiri

All issues in libracoder/kiri

Similar issues

More Rust issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.