mirror of
https://github.com/hauler-dev/hauler.git
synced 2026-08-27 14:07:17 +00:00
wip
This commit is contained in:
@@ -91,29 +91,18 @@ func (b *Bundle) ResolveBundleFromPath() error {
|
||||
}
|
||||
|
||||
func (b Bundle) Setup(d driver.Driver, path string) error {
|
||||
cwd, err := os.Getwd()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
defer os.Chdir(cwd)
|
||||
|
||||
err = os.Chdir(path)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
targetStatic := filepath.Join(d.VarPath(), d.AnonymousStaticPath(), b.Name)
|
||||
if err := safeSymlink(StaticDirectory, targetStatic); err != nil {
|
||||
if err := safeSymlink(filepath.Join(path, StaticDirectory), targetStatic); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
targetImages := filepath.Join(d.VarPath(), d.PreloadImagesPath(), b.Name)
|
||||
if err := safeSymlink(ImagePreloadDirectory, targetImages); err != nil {
|
||||
if err := safeSymlink(filepath.Join(path, ImagePreloadDirectory), targetImages); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
targetManifests := filepath.Join(d.VarPath(), d.AutodeployManifestsPath(), b.Name)
|
||||
if err := safeSymlink(AutodeployDirectory, targetManifests); err != nil {
|
||||
if err := safeSymlink(filepath.Join(path, AutodeployDirectory), targetManifests); err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
|
||||
@@ -96,7 +96,6 @@ func StartDriver(d driver.Driver) error {
|
||||
"INSTALL_K3S_SELINUX_WARN=true",
|
||||
"INSTALL_K3S_SKIP_SELINUX_RPM=true",
|
||||
"INSTALL_K3S_BIN_DIR=/opt/hauler/bin",
|
||||
"INSTALL_K3S_SKIP_START=true",
|
||||
}...)
|
||||
out, err := cmd.CombinedOutput()
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user