Skip to content

Commit

Permalink
fix: make bundle path in state absolute
Browse files Browse the repository at this point in the history
  • Loading branch information
nixpig committed Oct 8, 2024
1 parent 69cd435 commit 504b643
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion internal/container/container.go
Original file line number Diff line number Diff line change
Expand Up @@ -104,9 +104,14 @@ func New(
return nil, fmt.Errorf("copy rootfs: %w", err)
}

absBundlePath, err := filepath.Abs(bundle)
if err != nil {
return nil, fmt.Errorf("construct absolute bundle path: %w", err)
}

return &Container{
Root: root,
State: state.New(id, bundle, status),
State: state.New(id, absBundlePath, status),
Spec: &spec,
}, nil
}
Expand Down

0 comments on commit 504b643

Please sign in to comment.