diff --git a/bib/cmd/bootc-image-builder/main.go b/bib/cmd/bootc-image-builder/main.go index 035e4c0d..a49afed3 100644 --- a/bib/cmd/bootc-image-builder/main.go +++ b/bib/cmd/bootc-image-builder/main.go @@ -311,7 +311,7 @@ func manifestFromCobra(cmd *cobra.Command, args []string) ([]byte, *mTLSConfig, return nil, nil, err } - mTLS, err := extractTLSKeys(container, repos) + mTLS, err := extractTLSKeys(SimpleFileReader{}, repos) if err != nil { return nil, nil, err } diff --git a/bib/cmd/bootc-image-builder/mtls.go b/bib/cmd/bootc-image-builder/mtls.go index 4dd171c7..101a8e45 100644 --- a/bib/cmd/bootc-image-builder/mtls.go +++ b/bib/cmd/bootc-image-builder/mtls.go @@ -19,6 +19,12 @@ type fileReader interface { ReadFile(string) ([]byte, error) } +type SimpleFileReader struct{} + +func (SimpleFileReader) ReadFile(path string) ([]byte, error) { + return os.ReadFile(path) +} + func extractTLSKeys(reader fileReader, repoSets map[string][]rpmmd.RepoConfig) (*mTLSConfig, error) { var keyPath, certPath, caPath string for _, set := range repoSets {