solo-io / bumblebee

Get eBPF programs running from the cloud to the kernel in 1 line of bash
Apache License 2.0
1.26k stars 78 forks source link

Built ELF file via builder image owned by root #57

Open lgadban opened 2 years ago

lgadban commented 2 years ago

Version

main

Linux Version

N/A

Describe the bug

When iterating builds with the build container (not as sudo), the BPF ELF generated is owned by root, so successive builds fail until the ELF is manually removed e.g. via sudo

Steps to reproduce the bug

$ ./mybee build examples/tcpconnect/tcpconnect.c tcpconnect
Error: open examples/tcpconnect/tcpconnect.o: permission denied
2022/01/11 16:51:00 exiting: open examples/tcpconnect/tcpconnect.o: permission denied
 ls -al examples/tcpconnect/tcpconnect.o 
-rw-r--r-- 1 root root 731424 Jan 11 02:17 examples/tcpconnect/tcpconnect.o

Expected Behavior

UX allowing iteration without manual cleanup necessary

Additional Context

No response