Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

hyperV: Respect rootful option on machine init #20135

Merged
merged 1 commit into from
Sep 26, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions pkg/machine/e2e/init_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -174,10 +174,6 @@ var _ = Describe("podman machine init", func() {
})

It("machine init rootless docker.sock check", func() {
if testProvider.VMType() == machine.HyperVVirt {
//https://github.com/containers/podman/issues/20092
Skip("rootless is broken with hyperv")
}
i := initMachine{}
name := randomString()
session, err := mb.setName(name).setCmd(i.withImagePath(mb.imagePath)).run()
Expand Down
2 changes: 2 additions & 0 deletions pkg/machine/hyperv/machine.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,7 @@ func (m *HyperVMachine) writeIgnitionConfigFile(opts machine.InitOptions, user,
TimeZone: opts.TimeZone,
WritePath: m.IgnitionFile.GetPath(),
UID: m.UID,
Rootful: m.Rootful,
}

if err := ign.GenerateIgnitionConfig(); err != nil {
Expand Down Expand Up @@ -243,6 +244,7 @@ func (m *HyperVMachine) Init(opts machine.InitOptions) (bool, error) {
DiskSize: opts.DiskSize,
Memory: opts.Memory,
}
m.Rootful = opts.Rootful

// If the user provides an ignition file, we need to
// copy it into the conf dir
Expand Down