mirror of
https://github.com/kopia/kopia.git
synced 2026-01-25 14:58:00 -05:00
22 lines
463 B
Go
22 lines
463 B
Go
package server
|
|
|
|
import (
|
|
"context"
|
|
"net/http"
|
|
|
|
"github.com/kopia/kopia/internal/serverapi"
|
|
)
|
|
|
|
func (s *Server) handleStatus(ctx context.Context, r *http.Request) (interface{}, *apiError) {
|
|
bf := s.rep.Blocks.Format
|
|
bf.HMACSecret = nil
|
|
bf.MasterKey = nil
|
|
|
|
return &serverapi.StatusResponse{
|
|
ConfigFile: s.rep.ConfigFile,
|
|
CacheDir: s.rep.CacheDirectory,
|
|
BlockFormatting: bf,
|
|
Storage: s.rep.Storage.ConnectionInfo().Type,
|
|
}, nil
|
|
}
|