From 14277b2c85d638b77b68aacc282a758e004a2336 Mon Sep 17 00:00:00 2001 From: Jake Schuurmans Date: Fri, 4 Oct 2024 09:44:26 -0400 Subject: [PATCH] Add Bios Config URL --- condition/bios_control.go | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/condition/bios_control.go b/condition/bios_control.go index f7a4701..08b39bf 100644 --- a/condition/bios_control.go +++ b/condition/bios_control.go @@ -2,6 +2,7 @@ package condition import ( "encoding/json" + "net/url" "github.com/google/uuid" ) @@ -32,6 +33,12 @@ type BiosControlTaskParameters struct { // // Required: true Action BiosControlAction `json:"action"` + + // The URL for the bios configuration settings file. + // Needed for BiosControlAction.SetConfig + // + // Required: false + BiosConfigURL *url.URL `json:"bios_config_url,omitempty"` } func (p *BiosControlTaskParameters) Unmarshal(r json.RawMessage) error { @@ -50,10 +57,11 @@ func (p *BiosControlTaskParameters) MustJSON() []byte { return byt } -func NewBiosControlTaskParameters(assetID uuid.UUID, action BiosControlAction) *BiosControlTaskParameters { +func NewBiosControlTaskParameters(assetID uuid.UUID, action BiosControlAction, configURL *url.URL) *BiosControlTaskParameters { return &BiosControlTaskParameters{ - AssetID: assetID, - Action: action, + AssetID: assetID, + Action: action, + BiosConfigURL: configURL, } }