open-nomad/helper/users
Seth Hoenig 92d4a05534
users: eliminate nobody user memoization (#16904)
This PR eliminates code specific to looking up and caching the uid/gid/user.User
object associated with the nobody user in an init block. This code existed before
adding the generic users cache and was meant to optimize the one search path we
knew would happen often. Now that we have the cache, seems reasonable to eliminate
this init block and use the cache instead like for any other user.

Also fixes a constraint on the podman (and other) drivers, where building without
CGO became problematic on some OS like Fedora IoT where the nobody user cannot
be found with the pure-Go standard library.

Fixes github.com/hashicorp/nomad-driver-podman/issues/228
2023-04-17 12:30:30 -05:00
..
cache.go [COMPLIANCE] Add Copyright and License Headers 2023-04-10 15:36:59 +00:00
cache_test.go [COMPLIANCE] Add Copyright and License Headers 2023-04-10 15:36:59 +00:00
lookup.go [COMPLIANCE] Add Copyright and License Headers 2023-04-10 15:36:59 +00:00
lookup_linux_test.go users: eliminate nobody user memoization (#16904) 2023-04-17 12:30:30 -05:00
lookup_windows_test.go [COMPLIANCE] Add Copyright and License Headers 2023-04-10 15:36:59 +00:00