You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently there is no way to limit (i.e --limit) the host/group that an task is executed for when the task triggered from an Integration, ideally based on a parameter from the integration request (ie ExtractValue)
This means that, currently, if you want to achieve this, you would have to create a separate Ansible Task for every Host/Group, and also a separate corresponding integration, this can cause quite a lot of unnecessary duplication when you have lots of customers to run separately.
Implementation
Add a controlled list qualifier to specify whether an extract value is for Environment or TaskParams, and populate the Task object accordingly.
Design
A new additional parameter VariableType could be added to IntegrationExtractValue to differentiate whether a value is intended for Environment or for TaskParams
type IntegrationVariableType string
const (
IntegrationVariableEnvironment IntegrationVariableType = "environment"
IntegrationVariableTaskParam IntegrationVariableType = "task"
)
type IntegrationExtractValue struct {
ID int `db:"id" json:"id" backup:"-"`
IntegrationID int `db:"integration_id" json:"integration_id" backup:"-"`
Name string `db:"name" json:"name"`
ValueSource IntegrationExtractValueSource `db:"value_source" json:"value_source"`
BodyDataType IntegrationBodyDataType `db:"body_data_type" json:"body_data_type"`
Key string `db:"key" json:"key"`
Variable string `db:"variable" json:"variable"`
VariableType IntegrationVariableType `db:"variable_type" json:"variable_type"`
}
in the RunIntegration function we could separate the extraction of values into the corresponding Environment and TaskParams objects and pass them both into the Task creation so that limit (and other task variables) could be controlled.
The text was updated successfully, but these errors were encountered:
Related to
Web-Backend (APIs)
Impact
nice to have
Missing Feature
Currently there is no way to limit (i.e --limit) the host/group that an task is executed for when the task triggered from an Integration, ideally based on a parameter from the integration request (ie ExtractValue)
This means that, currently, if you want to achieve this, you would have to create a separate Ansible Task for every Host/Group, and also a separate corresponding integration, this can cause quite a lot of unnecessary duplication when you have lots of customers to run separately.
Implementation
Add a controlled list qualifier to specify whether an extract value is for Environment or TaskParams, and populate the Task object accordingly.
Design
A new additional parameter VariableType could be added to IntegrationExtractValue to differentiate whether a value is intended for Environment or for TaskParams
in the RunIntegration function we could separate the extraction of values into the corresponding Environment and TaskParams objects and pass them both into the Task creation so that limit (and other task variables) could be controlled.
The text was updated successfully, but these errors were encountered: