You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
My use case is probably fairly unusual and I do have a work around, but I was wondering if you'd be willing to consider adding an optional value to systemInfo struct that would place a prefix on all the paths to files? What I'm attempting to do is use this package inside a docker container and mount the host filesystem into the container in order to detect the host's info. Typically when this is done you'll mount the host's FS into a directory like /host so it doesn't collide with the container's FS. So if it was possible to set something like si.PathPrefix or whatever name you like that gets prepended to each of the currently hardcoded file paths that would be very useful. For now I'm able to simply mount the host's /etc dir directly over the container's /etc and it works as expected (I personally am most interested in the OS info, so only need etc), but it would be best, and allow expanded use cases, to keep the host and container FS's separated properly.
The text was updated successfully, but these errors were encountered:
While I do run lots of containers, somehow I haven't yet attempted to run sysinfo in a container. ;)
But, I'm certain it would be useful in many cases, so yes, I'd actually be willing to check the details and do what needs to be done, so that it can be used in a container enviroment more easily.
Even if sysinfo is actually a per-host thing, I see the beauty of orchestrating it (say via k8s daemonset) and using it that way to access host info.
I can't promise when I'll have enough time to investigate all that properly, but I can promise I'll come back to this topic ASAP. Together with all other ideas that I've collected in the meantime and just didn't have time to execute them yet. 😢
My use case is probably fairly unusual and I do have a work around, but I was wondering if you'd be willing to consider adding an optional value to systemInfo struct that would place a prefix on all the paths to files? What I'm attempting to do is use this package inside a docker container and mount the host filesystem into the container in order to detect the host's info. Typically when this is done you'll mount the host's FS into a directory like
/host
so it doesn't collide with the container's FS. So if it was possible to set something likesi.PathPrefix
or whatever name you like that gets prepended to each of the currently hardcoded file paths that would be very useful. For now I'm able to simply mount the host's/etc
dir directly over the container's/etc
and it works as expected (I personally am most interested in the OS info, so only need etc), but it would be best, and allow expanded use cases, to keep the host and container FS's separated properly.The text was updated successfully, but these errors were encountered: