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
We could use a common decision task protocol to add new tasks to the current Taskcluster group, after analyzing the target.
As we already have the logic to retrieve target's code and Taskcluster client's setup, we need 2 more things:
Support some rules to decide if a task is added or not
Create a new task for each approved one
The .taskcluster.yml file is built with json-e. We could leverage that, and add our own json-e functions while rendering the .taskcluster.yml file from any repository.
A common pattern is to trigger a task only if some file changed in the diff from current revision up to master.
To accomplish that, we could:
add a json-e function $files_changed(["pattern/*.cpp", "anything.txt"])
set the tasks_for variable to taskboot-decision
render the target .taskcluster.yml with these parameters
if any tasks payload is present in the rendered file, create those tasks.
On the target, the changes are:
add a taskboot decision task (using published image and command taskboot decision)
add the relevant tasks with the syntax:
tasks:
- $if "tasks_for == 'taskboot-decision' and $files_changed(['**.py'])"then...
The text was updated successfully, but these errors were encountered:
We could wait for https://hg.mozilla.org/ci/taskgraph/ to be ready, so we don't have to implement something custom but re-use something developers are already used to.
If it takes too long, this seems like a good idea to me. I wonder if Taskcluster will complain about the absence of $files_changed function though (since it's going to be implemented in taskboot, Taskcluster won't know about it, no?)
We could use a common decision task protocol to add new tasks to the current Taskcluster group, after analyzing the target.
As we already have the logic to retrieve target's code and Taskcluster client's setup, we need 2 more things:
The
.taskcluster.yml
file is built with json-e. We could leverage that, and add our own json-e functions while rendering the.taskcluster.yml
file from any repository.A common pattern is to trigger a task only if some file changed in the diff from current revision up to master.
To accomplish that, we could:
$files_changed(["pattern/*.cpp", "anything.txt"])
tasks_for
variable totaskboot-decision
.taskcluster.yml
with these parametersOn the target, the changes are:
taskboot decision
)The text was updated successfully, but these errors were encountered: