mirror of
https://github.com/lingble/talos.git
synced 2025-12-15 20:17:05 +00:00
feat: add Runtime interface
Instead of passing around a struct, it is better if we pass around an interface that describes the behavior we want. The Runtime interface provides a common place to describe runtime specific parameters. This initial implementation offers the runtime mode, the platform specifics, and the config. Signed-off-by: Andrew Rynhard <andrew@andrewrynhard.com>
This commit is contained in:
@@ -17,7 +17,7 @@ import (
|
||||
|
||||
"github.com/talos-systems/talos/internal/pkg/installer"
|
||||
"github.com/talos-systems/talos/internal/pkg/kernel"
|
||||
"github.com/talos-systems/talos/internal/pkg/platform"
|
||||
"github.com/talos-systems/talos/internal/pkg/runtime"
|
||||
"github.com/talos-systems/talos/pkg/blockdevice/probe"
|
||||
"github.com/talos-systems/talos/pkg/config/machine"
|
||||
"github.com/talos-systems/talos/pkg/constants"
|
||||
@@ -28,7 +28,7 @@ import (
|
||||
type Interactive struct{}
|
||||
|
||||
// Initialize implements the Initializer interface.
|
||||
func (i *Interactive) Initialize(platform platform.Platform, install machine.Install) (err error) {
|
||||
func (i *Interactive) Initialize(platform runtime.Platform, install machine.Install) (err error) {
|
||||
var dev *probe.ProbedBlockDevice
|
||||
|
||||
dev, err = probe.GetDevWithFileSystemLabel(constants.ISOFilesystemLabel)
|
||||
|
||||
Reference in New Issue
Block a user