Glare resources
Now:
I as a user want to create a workflow that uses some additional resources like shell scripts (e.g. through ssh), binaries, images etc. I have the following options:
* Do all processing involving these resources out of mistral via asynchronous actions. We just delegate to an external system.
- Pros:
* Very generic and flexible, we can implement any processing logic in an external system (e.g. services with REST API)
- Cons:
* We have to create some external system that takes care of processing workflow tasks (more precisely, actions)
* If we need only shell scripts we can write them right in the workflow text
- Pros:
* We see the full text of the script right in the workflow
- Cons:
* If the script is big then workflow text becomes unreadable
The goal:
* Be able to use Glare as an external storage for workflow resources
* Define the syntax how references to Glare resources should look like in Mistral workflows
* Create a new Glare artifact type to be able to store workflows with resources in Glare
* Mistral CLI commands that allow to upload resources in Glare in a convenient way (e.g. one command to create a wf in Mistral and upload resources to Glare)
Solution ideas/steps:
* Keep all resources needed by a workflow in Glare so that the workflow operates only with references (URIs) pointing to needed resources. At a particular place where the references is used the content of the resource gets requested from Glare.
* Create a spec
* Config property pointing to Glare base url (glare_url=https:/
Workflow example:
heal_vms_wf:
input:
- hosts
- heal_vm_script: "1230123-
tasks:
heal_vms:
with-items: host in <% $.hosts %>
action: std.ssh cmd=<% $. heal_vm_script %> host=<% $.host %>
Questions:
* How do we specify that a link points to a Glare artefact? (Imagine if we want to support multiple link types). It would be cool to have something like: glare:/
* How do we address a resource in a convenient way w/o having to know artefact id? Idea: glare:/
* How do we add Glare resources? Idea: mistral workflow-create my_wf.yaml --resource my_sh_script=
mistral workflow-create my_wf.yaml --resource my_sh_script=
workflowartifact:
name:my_wf
version:1.0
resources:
glare:/
Links:
* https:/
* http://
Blueprint information
- Status:
- Not started
- Approver:
- Renat Akhmerov
- Priority:
- High
- Drafter:
- Renat Akhmerov
- Direction:
- Approved
- Assignee:
- None
- Definition:
- New
- Series goal:
- None
- Implementation:
- Not started
- Milestone target:
- None
- Started by
- Completed by