mirror of
https://github.com/kairos-io/kairos-sdk.git
synced 2025-07-06 03:36:28 +00:00
It was added first to agent as it was needed for upgrade but if we are gonna reuse this to check for signature validity in random files, we better have it on sdk so we can use it both on agent and immucore and works exactly the same Signed-off-by: Itxaka <itxaka@kairos.io>
16 lines
349 B
Go
16 lines
349 B
Go
package types
|
|
|
|
import (
|
|
"io/fs"
|
|
"os"
|
|
)
|
|
|
|
// KairosFS is our interface for methods that need an FS
|
|
type KairosFS interface {
|
|
ReadFile(filename string) ([]byte, error)
|
|
Stat(name string) (fs.FileInfo, error)
|
|
Open(name string) (fs.File, error)
|
|
RawPath(name string) (string, error)
|
|
WriteFile(filename string, data []byte, perm os.FileMode) error
|
|
}
|