constellation/image/upload/internal/cmd/api.go

26 lines
534 B
Go
Raw Normal View History

/*
Copyright (c) Edgeless Systems GmbH
SPDX-License-Identifier: AGPL-3.0-only
*/
package cmd
import (
"context"
"io"
"github.com/edgelesssys/constellation/v2/internal/api/versionsapi"
"github.com/edgelesssys/constellation/v2/internal/osimage"
)
type archivist interface {
Archive(ctx context.Context,
2023-05-23 03:17:27 -04:00
version versionsapi.Version, csp, attestationVariant string, img io.Reader,
) (string, error)
}
type uploader interface {
2023-05-23 03:17:27 -04:00
Upload(ctx context.Context, req *osimage.UploadRequest) ([]versionsapi.ImageInfoEntry, error)
}