1
0
Fork 0
mirror of https://github.com/kubernetes-sigs/node-feature-discovery.git synced 2024-12-14 11:57:51 +00:00

source/system: Add reading product name information

This commit is contained in:
Kazuki Suda 2024-09-10 14:42:08 +09:00
parent c07f71e934
commit 7f6669eb92
No known key found for this signature in database
GPG key ID: F735607417C95F32
2 changed files with 2 additions and 1 deletions

View file

@ -1027,6 +1027,7 @@ The following features are available for matching:
| | | **`<parameter>`** | string | One parameter from `/etc/os-release` |
| **`system.dmiid`** | attribute | | | DMI identification data from `/sys/devices/virtual/dmi/id/` |
| | | **`sys_vendor`** | string | Vendor name from `/sys/devices/virtual/dmi/id/sys_vendor` |
| | | **`product_name`** | string | Product name from `/sys/devices/virtual/dmi/id/product_name` |
| **`system.name`** | attribute | | | System name information |
| | | **`nodename`** | string | Name of the kubernetes node object |
| **`usb.device`** | instance | | | USB devices present in the system |

View file

@ -103,7 +103,7 @@ func (s *systemSource) Discover() error {
}
// Get DMI ID attributes
dmiIDAttributeNames := []string{"sys_vendor"}
dmiIDAttributeNames := []string{"sys_vendor", "product_name"}
dmiAttrs := make(map[string]string)
for _, name := range dmiIDAttributeNames {
val, err := getDmiIDAttribute(name)