func NewRepos(ctx context.Context, log logr.Logger) Repos {
	logging.TraceCall(log)
	defer logging.TraceExit(log)
	return &reposData{
		repos:    make(map[string]Repo, 1),
		ctx:      ctx,
		log:      log,
		rootPath: DefaultRootPath,
		hostName: DefaultHostName,
		timeOut:  DefaultTimeOut,
		client:   &http.Client{},
	}
}
NewRepos creates a repos object.
package repos
import (
	"context"
	"fmt"
	"io/ioutil"
	"net/http"
	"os"
	"strings"
	"sync"
	"time"
	sourcev1 "github.com/fluxcd/source-controller/api/v1beta1"
	"github.com/go-logr/logr"
	"github.com/pkg/errors"
	"github.com/fidelity/kraan/pkg/common"
	"github.com/fidelity/kraan/pkg/internal/tarconsumer"
	"github.com/fidelity/kraan/pkg/logging"
)
var (
	DefaultRootPath = "/data"
	DefaultHostName = ""
	DefaultTimeOut  = 15 * time.Second
)
type Repos interface {
	Add(srcRepo *sourcev1.GitRepository) Repo
	Get(name string) Repo
	Delete(name string)
	List() map[string]Repo
	SetRootPath(path string)
	GetRootPath() string
	SetHostName(hostName string)
	SetTimeOut(timeOut time.Duration)
	SetHTTPClient(client *http.Client)
}
type reposData struct {
	repos        map[string]Repo
	ctx          context.Context
	log          logr.Logger
	rootPath     string
	hostName     string
	timeOut      time.Duration
	client       *http.Client
	Repos        `json:"-"`
	sync.RWMutex `json:"-"`
}