canonical / gomaasclient

Go MAAS client
Apache License 2.0
22 stars 28 forks source link

Running testing scripts is not supported #102

Closed gnuoy closed 1 week ago

gnuoy commented 1 month ago

Running testing script (such as ntp, memtester, stress-ng etc) is not supported directly. It can be done via the deprecated API client with something like:

    values := make(url.Values)
    values.Add("testing_scripts", strings.Join(testScripts, ","))

    machine := new(entity.Machine)
    machineAPI := APIClient.GetSubObject("machines").GetSubObject(machineData.SystemID)
    err := machineAPI.Post("test", values, func(data []byte) error {
        return json.Unmarshal(data, machine)
    })
github-actions[bot] commented 4 weeks ago

This issue is stale because it has been open for 30 days with no activity.

skatsaounis commented 1 week ago

Hi @gnuoy . Thank you for opening the issue. I am marking it as duplicate of #96, which includes the op-test implementation