Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EnsureDirectoryExists ¶
EnsureDirectoryExists creates a directory if it does not exist it returns an error if it fails
func EnsureSymbolicLink ¶
EnsureSymbolicLink preserves a correct link and replaces any other target.
func ExtractBinary ¶
ExtractBinary extracts a zstd-compressed binary and installs it to destFile. TODO: get the SHA of each binary and compare it to the expected SHA
func FileExists ¶
FileExists checks if a file exists it returns true if the file exists, false otherwise
func RemoveIfSymlink ¶ added in v1.2.0
RemoveIfSymlink removes path only when it is a symlink, and reports whether it did. A regular file, directory or socket at that path is left untouched.
This guards the shared paths kubesolo publishes itself into, such as the standard containerd socket: kubesolo installs a symlink there, whereas a container runtime managed by the host binds a real socket at the same path. os.Stat follows symlinks and so cannot tell the two apart; os.Lstat does not.
Types ¶
This section is empty.