mirror of
https://github.com/hauler-dev/hauler.git
synced 2026-08-27 14:07:17 +00:00
add some tests for image discovery, flesh out boot process
This commit is contained in:
@@ -71,6 +71,8 @@ func (o *deployOpts) Run(packagePath string) error {
|
||||
return err
|
||||
}
|
||||
|
||||
d := v1alpha1.NewDriver(p.Spec.Driver.Kind)
|
||||
|
||||
b, err := bootstrap.NewBooter(tmpdir)
|
||||
if err != nil {
|
||||
return err
|
||||
@@ -82,14 +84,21 @@ func (o *deployOpts) Run(packagePath string) error {
|
||||
}
|
||||
|
||||
o.logger.Infof("Performing pre %s boot steps", p.Spec.Driver.Kind)
|
||||
if err := b.PreBoot(ctx, d); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
o.logger.Infof("Booting %s", p.Spec.Driver.Kind)
|
||||
if err := b.Boot(ctx, d); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
o.logger.Infof("Performing post %s boot steps", p.Spec.Driver.Kind)
|
||||
if err := b.PostBoot(ctx, d); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
o.logger.Infof("Success!")
|
||||
|
||||
_ = ctx
|
||||
o.logger.Infof("Success! You can access the cluster with '/opt/hauler/bin/kubectl'")
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
@@ -1,13 +0,0 @@
|
||||
apiVersion: hauler.cattle.io/v1alpha1
|
||||
kind: Package
|
||||
metadata:
|
||||
creationTimestamp: null
|
||||
name: test
|
||||
spec:
|
||||
driver:
|
||||
kind: k3s
|
||||
version: v1.21.1+k3s1
|
||||
fleet:
|
||||
version: 0.3.5
|
||||
paths:
|
||||
- ../../../testdata/rawmanifests
|
||||
Reference in New Issue
Block a user