Sybren A. Stüvel aa9837b5f0 First incarnation of the first-time wizard
This adds a `-wizard` CLI option to the Manager, which opens a webbrowser
and shows the First-Time Wizard to aid in configuration of Flamenco.

This is work in progress. The wizard is just one page, and doesn't save
anything yet to the configuration.
2022-07-14 11:17:03 +02:00

34 lines
1.1 KiB
Go

package dummy
import (
"context"
"errors"
"io"
"git.blender.org/flamenco/internal/manager/api_impl"
"git.blender.org/flamenco/pkg/api"
)
// DummyShaman implements the Shaman interface from `internal/manager/api_impl/interfaces.go`
type DummyShaman struct{}
var _ api_impl.Shaman = (*DummyShaman)(nil)
var ErrDummyShaman = errors.New("Shaman storage component is inactive, configure Flamenco first")
func (ds *DummyShaman) IsEnabled() bool {
return false
}
func (ds *DummyShaman) Checkout(ctx context.Context, checkout api.ShamanCheckout) (string, error) {
return "", ErrDummyShaman
}
func (ds *DummyShaman) Requirements(ctx context.Context, requirements api.ShamanRequirementsRequest) (api.ShamanRequirementsResponse, error) {
return api.ShamanRequirementsResponse{}, ErrDummyShaman
}
func (ds *DummyShaman) FileStoreCheck(ctx context.Context, checksum string, filesize int64) api.ShamanFileStatus {
return api.ShamanFileStatusUnknown
}
func (ds *DummyShaman) FileStore(ctx context.Context, file io.ReadCloser, checksum string, filesize int64, canDefer bool, originalFilename string) error {
return ErrDummyShaman
}