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

Agent exec args #124

Merged
merged 4 commits into from
Mar 7, 2024
Merged
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: 2 additions & 2 deletions virtual_machine.go
Original file line number Diff line number Diff line change
Expand Up @@ -501,10 +501,10 @@
}
}

func (v *VirtualMachine) AgentExec(ctx context.Context, command, inputData string) (pid int, err error) {
func (v *VirtualMachine) AgentExec(ctx context.Context, command []string, inputData string) (pid int, err error) {

Check warning on line 504 in virtual_machine.go

View check run for this annotation

Codecov / codecov/patch

virtual_machine.go#L504

Added line #L504 was not covered by tests
tmpdata := map[string]interface{}{}
err = v.client.Post(ctx, fmt.Sprintf("/nodes/%s/qemu/%d/agent/exec", v.Node, v.VMID),
map[string]string{
map[string]interface{}{

Check warning on line 507 in virtual_machine.go

View check run for this annotation

Codecov / codecov/patch

virtual_machine.go#L507

Added line #L507 was not covered by tests
"command": command,
"input-data": inputData,
},
Expand Down
Loading