I get the following error why i run keectl: Failed...
# fleet
n
I get the following error why i run keectl: Failed to fetch user info for home directory: user: current requires cgo or $USER set in environment 2023/10/19 100 <nil>
g
Hey @nick fury Are you getting these errors with fleetctl and what does the environment look like? Thinking is possibly container without user setup
n
i deployed it in helm setup of fleet
g
@nick fury what is going on when you gett this error? What is your infrastructure like and version of Fleet?
n
it when i try to run fleetctl im using fleet 3.8.1 i tired also a little oder versions
k
It sounds like the environment where
fleetctl
is running doesn't have a user (as @Grant Bilstad mentioned). How exactly are you running
fleetctl
? The more information you can give us about what you're trying to do with
fleetctl
and the process you're using, the better.
n
what do you mean how i am deployed it? I deployed it with official helm of fleet and official fleet image
k
What process is happening when you see this error?
Is it fleetctl that's throwing the error, Fleet itself, or something else?
n
just the output of fleeetctl
when i type fleetctl in the container
k
Can you show me a screenshot?
n
i can't 😞 , but I will tell exactly what i do step after step 1. exec info fleet docker 2. i write fleetctl 3. get the folowing error : "Failed to fetch user info for home directory: user: current requires cgo or $USER set in environment 2023/10/19 100 <nil>"
k
You do need an active user with a home directory in order to run fleetctl, so you'd need to set up that container accordingly. I'd generally recommend running fleetctl locally rather than in the container. It just needs to be able to reach the server over the network.
n
"I'd generally recommend running fleetctl locally rather than in the container. It just needs to be able to reach the server over the networkI'd generally recommend running fleetctl locally rather than in the container. It just needs to be able to reach the server over the network" why is that?
"You do need an active user with a home directory in order to run fleetctl, so you'd need to set up that container accordingly." thanks!
k
Mostly just because running it in a container means you need to take extra steps when you want to use it 🙂 I use fleetctl a lot, so I tend to focus on the path of least resistance.