diff --git a/CHANGELOG.rst b/CHANGELOG.rst index db098b39e3..1a3a580631 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -16,7 +16,7 @@ Added to pants' use of PEX lockfiles. This is not a user-facing addition. #5778 #5789 #5817 #5795 #5830 #5833 #5834 #5841 #5840 #5838 #5842 #5837 #5849 #5850 #5846 #5853 #5848 #5847 #5858 #5857 #5860 #5868 #5871 #5864 #5874 #5884 #5893 #5891 - #5890 #5898 #5901 #5906 #5899 + #5890 #5898 #5901 #5906 #5899 #5907 Contributed by @cognifloyd * Added a joint index to solve the problem of slow mongo queries for scheduled executions. #5805 diff --git a/contrib/runners/action_chain_runner/BUILD b/contrib/runners/action_chain_runner/BUILD new file mode 100644 index 0000000000..229eb12728 --- /dev/null +++ b/contrib/runners/action_chain_runner/BUILD @@ -0,0 +1,12 @@ +st2_runner_python_distribution( + runner_name="action_chain", + description=( + "Action-Chain workflow action runner " + "for the StackStorm event-driven automation platform" + ), + entry_points={ + stevedore_namespace("st2common.runners.runner"): { + "action-chain": "action_chain_runner.action_chain_runner", + }, + }, +) diff --git a/contrib/runners/announcement_runner/BUILD b/contrib/runners/announcement_runner/BUILD new file mode 100644 index 0000000000..e401a42867 --- /dev/null +++ b/contrib/runners/announcement_runner/BUILD @@ -0,0 +1,12 @@ +st2_runner_python_distribution( + runner_name="announcement", + description=( + "Announcement action runner " + "for the StackStorm event-driven automation platform" + ), + entry_points={ + stevedore_namespace("st2common.runners.runner"): { + "announcement": "announcement_runner.announcement_runner", + }, + }, +) diff --git a/contrib/runners/http_runner/BUILD b/contrib/runners/http_runner/BUILD new file mode 100644 index 0000000000..9773d48d3c --- /dev/null +++ b/contrib/runners/http_runner/BUILD @@ -0,0 +1,11 @@ +st2_runner_python_distribution( + runner_name="http", + description=( + "HTTP(s) action runner for the StackStorm event-driven automation platform" + ), + entry_points={ + stevedore_namespace("st2common.runners.runner"): { + "http-request": "http_runner.http_runner", + }, + }, +) diff --git a/contrib/runners/inquirer_runner/BUILD b/contrib/runners/inquirer_runner/BUILD new file mode 100644 index 0000000000..e50ae2ead8 --- /dev/null +++ b/contrib/runners/inquirer_runner/BUILD @@ -0,0 +1,11 @@ +st2_runner_python_distribution( + runner_name="inquirer", + description=( + "Inquirer action runner for the StackStorm event-driven automation platform" + ), + entry_points={ + stevedore_namespace("st2common.runners.runner"): { + "inquirer": "inquirer_runner.inquirer_runner", + }, + }, +) diff --git a/contrib/runners/local_runner/BUILD b/contrib/runners/local_runner/BUILD new file mode 100644 index 0000000000..b2b98fcce5 --- /dev/null +++ b/contrib/runners/local_runner/BUILD @@ -0,0 +1,13 @@ +st2_runner_python_distribution( + runner_name="local", + description=( + "Local Shell Command and Script action runner " + "for the StackStorm event-driven automation platform" + ), + entry_points={ + stevedore_namespace("st2common.runners.runner"): { + "local-shell-cmd": "local_runner.local_shell_command_runner", + "local-shell-script": "local_runner.local_shell_script_runner", + }, + }, +) diff --git a/contrib/runners/noop_runner/BUILD b/contrib/runners/noop_runner/BUILD new file mode 100644 index 0000000000..964dbb3de0 --- /dev/null +++ b/contrib/runners/noop_runner/BUILD @@ -0,0 +1,11 @@ +st2_runner_python_distribution( + runner_name="noop", + description=( + "No-Op action runner for the StackStorm event-driven automation platform" + ), + entry_points={ + stevedore_namespace("st2common.runners.runner"): { + "noop": "noop_runner.noop_runner", + }, + }, +) diff --git a/contrib/runners/orquesta_runner/BUILD b/contrib/runners/orquesta_runner/BUILD new file mode 100644 index 0000000000..7d9cfa642d --- /dev/null +++ b/contrib/runners/orquesta_runner/BUILD @@ -0,0 +1,43 @@ +st2_runner_python_distribution( + runner_name="orquesta", + description=( + "Orquesta workflow runner " + "for the StackStorm event-driven automation platform" + ), + entry_points={ + stevedore_namespace("st2common.runners.runner"): { + "orquesta": "orquesta_runner.orquesta_runner", + }, + stevedore_namespace("orquesta.expressions.functions"): { + "st2kv": "orquesta_functions.st2kv:st2kv_", + "task": "orquesta_functions.runtime:task", + "basename": "st2common.expressions.functions.path:basename", + "dirname": "st2common.expressions.functions.path:dirname", + "from_json_string": "st2common.expressions.functions.data:from_json_string", + "from_yaml_string": "st2common.expressions.functions.data:from_yaml_string", + "json_dump": "st2common.expressions.functions.data:to_json_string", + "json_parse": "st2common.expressions.functions.data:from_json_string", + "json_escape": "st2common.expressions.functions.data:json_escape", + "jsonpath_query": "st2common.expressions.functions.data:jsonpath_query", + "regex_match": "st2common.expressions.functions.regex:regex_match", + "regex_replace": "st2common.expressions.functions.regex:regex_replace", + "regex_search": "st2common.expressions.functions.regex:regex_search", + "regex_substring": "st2common.expressions.functions.regex:regex_substring", + "to_human_time_from_seconds": "st2common.expressions.functions.time:to_human_time_from_seconds", + "to_json_string": "st2common.expressions.functions.data:to_json_string", + "to_yaml_string": "st2common.expressions.functions.data:to_yaml_string", + "use_none": "st2common.expressions.functions.data:use_none", + "version_compare": "st2common.expressions.functions.version:version_compare", + "version_more_than": "st2common.expressions.functions.version:version_more_than", + "version_less_than": "st2common.expressions.functions.version:version_less_than", + "version_equal": "st2common.expressions.functions.version:version_equal", + "version_match": "st2common.expressions.functions.version:version_match", + "version_bump_major": "st2common.expressions.functions.version:version_bump_major", + "version_bump_minor": "st2common.expressions.functions.version:version_bump_minor", + "version_bump_patch": "st2common.expressions.functions.version:version_bump_patch", + "version_strip_patch": "st2common.expressions.functions.version:version_strip_patch", + "yaml_dump": "st2common.expressions.functions.data:to_yaml_string", + "yaml_parse": "st2common.expressions.functions.data:from_yaml_string", + }, + }, +) diff --git a/contrib/runners/python_runner/BUILD b/contrib/runners/python_runner/BUILD new file mode 100644 index 0000000000..0f6630d3f5 --- /dev/null +++ b/contrib/runners/python_runner/BUILD @@ -0,0 +1,12 @@ +st2_runner_python_distribution( + runner_name="python", + description=( + "Python action runner for the StackStorm event-driven automation platform" + ), + entry_points={ + stevedore_namespace("st2common.runners.runner"): { + "python-script": "python_runner.python_runner", + }, + }, + zip_safe=False, +) diff --git a/contrib/runners/remote_runner/BUILD b/contrib/runners/remote_runner/BUILD new file mode 100644 index 0000000000..b6dbb3fcc3 --- /dev/null +++ b/contrib/runners/remote_runner/BUILD @@ -0,0 +1,13 @@ +st2_runner_python_distribution( + runner_name="remote", + description=( + "Remote SSH shell command and script action runner " + "for the StackStorm event-driven automation platform" + ), + entry_points={ + stevedore_namespace("st2common.runners.runner"): { + "remote-shell-cmd": "remote_runner.remote_command_runner", + "remote-shell-script": "remote_runner.remote_script_runner", + }, + }, +) diff --git a/contrib/runners/winrm_runner/BUILD b/contrib/runners/winrm_runner/BUILD index a6be53dbd1..c66877afa4 100644 --- a/contrib/runners/winrm_runner/BUILD +++ b/contrib/runners/winrm_runner/BUILD @@ -5,3 +5,18 @@ python_requirement( # https://github.com/pantsbuild/pants/pull/17390 modules=["winrm"], ) + +st2_runner_python_distribution( + runner_name="winrm", + description=( + "WinRM shell command and PowerShell command and script action runner " + "for the StackStorm event-driven automation platform" + ), + entry_points={ + stevedore_namespace("st2common.runners.runner"): { + "winrm-cmd": "winrm_runner.winrm_command_runner", + "winrm-ps-cmd": "winrm_runner.winrm_ps_command_runner", + "winrm-ps-script": "winrm_runner.winrm_ps_script_runner", + }, + }, +) diff --git a/pants-plugins/macros.py b/pants-plugins/macros.py index f9a7c86397..79fad0091b 100644 --- a/pants-plugins/macros.py +++ b/pants-plugins/macros.py @@ -13,6 +13,11 @@ # limitations under the License. +# this is only here temporarily until we update to pants 2.16+ +def stevedore_namespace(ns): + return ns + + def st2_publish_repos(): """Return the list of repos twine should publish to.