{
"id": 37,
"pipeline_json": {
"nodes": [
{
"position": {
"x": 150,
"y": 120
},
"size": {
"width": 186,
"height": 65
},
"view": "react-shape-view",
"shape": "job",
"ports": {
"groups": {
"top": {
"position": {
"name": "top",
"args": {
"dx": 0
}
},
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"bottom": {
"position": {
"name": "bottom",
"args": {
"dx": 0
}
},
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"left": {
"position": "left",
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"right": {
"position": "right",
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
}
},
"items": [
{
"id": "on-push-81a68a8-left",
"group": "left"
},
{
"id": "on-push-81a68a8-right",
"group": "right"
},
{
"id": "on-push-81a68a8-top",
"group": "top"
},
{
"id": "on-push-81a68a8-bottom",
"group": "bottom"
}
]
},
"id": "on-push-81a68a8",
"data": {
"id": "on-push-81a68a8",
"label": "代码push事件",
"name": "on-push",
"full_name": "on-push",
"description": "GitLink仓库push事件",
"icon": "https://osredm.com/api/attachments/7fe3f4b4-0752-4b22-8ac0-1b0c72416724",
"action_node_types_id": 3,
"yaml": "",
"sort_no": 0,
"use_count": 0,
"node_type": "start",
"is_mutil_link": true,
"link_type": "job",
"inputs": [
{
"id": 6,
"name": "branches",
"input_type": "input",
"description": "分支名称,多个分支英文逗号隔开,如'master,dev'",
"is_required": true,
"default_value": "master",
"value": "master"
},
{
"id": 7,
"name": "paths-ignore",
"input_type": "input",
"description": "忽略文件,多个文件英文逗号隔开,如'**.md,**.yaml'",
"is_required": false,
"default_value": null,
"value": null
}
],
"x": 566,
"y": 454,
"img": "https://osredm.com/api/attachments/7fe3f4b4-0752-4b22-8ac0-1b0c72416724",
"branches": "master",
"paths-ignore": null
},
"zIndex": 1
},
{
"position": {
"x": 420,
"y": 120
},
"size": {
"width": 186,
"height": 65
},
"view": "react-shape-view",
"shape": "job",
"ports": {
"groups": {
"top": {
"position": {
"name": "top",
"args": {
"dx": 0
}
},
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"bottom": {
"position": {
"name": "bottom",
"args": {
"dx": 0
}
},
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"left": {
"position": "left",
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"right": {
"position": "right",
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
}
},
"items": [
{
"id": "job-18f4d4af-left",
"group": "left"
},
{
"id": "job-18f4d4af-right",
"group": "right"
},
{
"id": "job-18f4d4af-top",
"group": "top"
},
{
"id": "job-18f4d4af-bottom",
"group": "bottom"
}
]
},
"id": "job-18f4d4af",
"data": {
"id": 24,
"label": "任务",
"name": "job",
"full_name": "",
"description": "",
"icon": "",
"action_node_types_id": 7,
"yaml": "",
"sort_no": 0,
"use_count": 0,
"node_type": "job",
"is_mutil_link": true,
"link_type": "job,step",
"inputs": [],
"x": 900,
"y": 461,
"img": ""
},
"zIndex": 3
},
{
"position": {
"x": 431,
"y": 306.625
},
"size": {
"width": 166,
"height": 51
},
"view": "react-shape-view",
"shape": "step",
"ports": {
"groups": {
"top": {
"position": {
"name": "top",
"args": {
"dx": 0
}
},
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"bottom": {
"position": {
"name": "bottom",
"args": {
"dx": 0
}
},
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"left": {
"position": "left",
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"right": {
"position": "right",
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
}
},
"items": [
{
"id": "shell-992db95-left",
"group": "left"
},
{
"id": "shell-992db95-right",
"group": "right"
},
{
"id": "shell-992db95-top",
"group": "top"
},
{
"id": "shell-992db95-bottom",
"group": "bottom"
}
]
},
"id": "shell-992db95",
"data": {
"id": "shell-992db95",
"label": "运行Shell脚本",
"name": "shell",
"full_name": "shell",
"description": "",
"icon": "https://osredm.com/api/attachments/91c6873b-a117-4771-a5ea-7f9e3f2d9a3a",
"action_node_types_id": 4,
"yaml": "",
"sort_no": 0,
"use_count": 0,
"node_type": "step",
"is_mutil_link": false,
"link_type": "step",
"inputs": [
{
"id": 3,
"name": "run",
"input_type": "input",
"description": null,
"is_required": false,
"default_value": null,
"value": "echo 111"
}
],
"x": 819,
"y": 589,
"img": "https://osredm.com/api/attachments/91c6873b-a117-4771-a5ea-7f9e3f2d9a3a",
"run": "echo 111"
},
"zIndex": 2
}
],
"edges": [
{
"shape": "data-processing-curve",
"inherit": "edge",
"connector": {
"name": "rounded",
"args": {
"radius": 10
}
},
"router": {
"name": "manhattan"
},
"attrs": {
"line": {
"strokeDasharray": "0"
}
},
"id": "39159699-26b7-4db8-99c0-9088be560a22",
"zIndex": -1,
"source": {
"cell": "on-push-81a68a8",
"port": "on-push-81a68a8-right"
},
"target": {
"cell": "job-18f4d4af",
"port": "job-18f4d4af-left"
}
},
{
"shape": "data-processing-curve",
"inherit": "edge",
"connector": {
"name": "rounded",
"args": {
"radius": 10
}
},
"router": {
"name": "manhattan"
},
"attrs": {
"line": {
"strokeWidth": 1,
"strokeDasharray": "3"
}
},
"id": "3c6f7387-74d5-4af1-a2f7-8520ed7b446e",
"zIndex": -1,
"source": {
"cell": "job-18f4d4af",
"port": "job-18f4d4af-bottom"
},
"target": {
"cell": "shell-992db95",
"port": "shell-992db95-top"
}
}
]
}
}curl --location --request POST 'https://testforgeplus.trustie.net/api/v1///pipelines/save_yaml' \
--header 'Cookie: autologin_trustie=3acc38c27d61a347f5c16fbca2c4964b181a2f79;autologin_trustie=3acc38c27d61a347f5c16fbca2c4964b181a2f79;autologin_trustie=3acc38c27d61a347f5c16fbca2c4964b181a2f79' \
--header 'Content-Type: application/json' \
--data-raw '{
"id": 37,
"pipeline_json": {
"nodes": [
{
"position": {
"x": 150,
"y": 120
},
"size": {
"width": 186,
"height": 65
},
"view": "react-shape-view",
"shape": "job",
"ports": {
"groups": {
"top": {
"position": {
"name": "top",
"args": {
"dx": 0
}
},
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"bottom": {
"position": {
"name": "bottom",
"args": {
"dx": 0
}
},
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"left": {
"position": "left",
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"right": {
"position": "right",
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
}
},
"items": [
{
"id": "on-push-81a68a8-left",
"group": "left"
},
{
"id": "on-push-81a68a8-right",
"group": "right"
},
{
"id": "on-push-81a68a8-top",
"group": "top"
},
{
"id": "on-push-81a68a8-bottom",
"group": "bottom"
}
]
},
"id": "on-push-81a68a8",
"data": {
"id": "on-push-81a68a8",
"label": "代码push事件",
"name": "on-push",
"full_name": "on-push",
"description": "GitLink仓库push事件",
"icon": "https://osredm.com/api/attachments/7fe3f4b4-0752-4b22-8ac0-1b0c72416724",
"action_node_types_id": 3,
"yaml": "",
"sort_no": 0,
"use_count": 0,
"node_type": "start",
"is_mutil_link": true,
"link_type": "job",
"inputs": [
{
"id": 6,
"name": "branches",
"input_type": "input",
"description": "分支名称,多个分支英文逗号隔开,如'\''master,dev'\''",
"is_required": true,
"default_value": "master",
"value": "master"
},
{
"id": 7,
"name": "paths-ignore",
"input_type": "input",
"description": "忽略文件,多个文件英文逗号隔开,如'\''**.md,**.yaml'\''",
"is_required": false,
"default_value": null,
"value": null
}
],
"x": 566,
"y": 454,
"img": "https://osredm.com/api/attachments/7fe3f4b4-0752-4b22-8ac0-1b0c72416724",
"branches": "master",
"paths-ignore": null
},
"zIndex": 1
},
{
"position": {
"x": 420,
"y": 120
},
"size": {
"width": 186,
"height": 65
},
"view": "react-shape-view",
"shape": "job",
"ports": {
"groups": {
"top": {
"position": {
"name": "top",
"args": {
"dx": 0
}
},
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"bottom": {
"position": {
"name": "bottom",
"args": {
"dx": 0
}
},
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"left": {
"position": "left",
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"right": {
"position": "right",
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
}
},
"items": [
{
"id": "job-18f4d4af-left",
"group": "left"
},
{
"id": "job-18f4d4af-right",
"group": "right"
},
{
"id": "job-18f4d4af-top",
"group": "top"
},
{
"id": "job-18f4d4af-bottom",
"group": "bottom"
}
]
},
"id": "job-18f4d4af",
"data": {
"id": 24,
"label": "任务",
"name": "job",
"full_name": "",
"description": "",
"icon": "",
"action_node_types_id": 7,
"yaml": "",
"sort_no": 0,
"use_count": 0,
"node_type": "job",
"is_mutil_link": true,
"link_type": "job,step",
"inputs": [],
"x": 900,
"y": 461,
"img": ""
},
"zIndex": 3
},
{
"position": {
"x": 431,
"y": 306.625
},
"size": {
"width": 166,
"height": 51
},
"view": "react-shape-view",
"shape": "step",
"ports": {
"groups": {
"top": {
"position": {
"name": "top",
"args": {
"dx": 0
}
},
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"bottom": {
"position": {
"name": "bottom",
"args": {
"dx": 0
}
},
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"left": {
"position": "left",
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
},
"right": {
"position": "right",
"attrs": {
"circle": {
"r": 5,
"magnet": true,
"strokeWidth": 1,
"fill": "#fff",
"stroke": "#85A5FF"
}
}
}
},
"items": [
{
"id": "shell-992db95-left",
"group": "left"
},
{
"id": "shell-992db95-right",
"group": "right"
},
{
"id": "shell-992db95-top",
"group": "top"
},
{
"id": "shell-992db95-bottom",
"group": "bottom"
}
]
},
"id": "shell-992db95",
"data": {
"id": "shell-992db95",
"label": "运行Shell脚本",
"name": "shell",
"full_name": "shell",
"description": "",
"icon": "https://osredm.com/api/attachments/91c6873b-a117-4771-a5ea-7f9e3f2d9a3a",
"action_node_types_id": 4,
"yaml": "",
"sort_no": 0,
"use_count": 0,
"node_type": "step",
"is_mutil_link": false,
"link_type": "step",
"inputs": [
{
"id": 3,
"name": "run",
"input_type": "input",
"description": null,
"is_required": false,
"default_value": null,
"value": "echo 111"
}
],
"x": 819,
"y": 589,
"img": "https://osredm.com/api/attachments/91c6873b-a117-4771-a5ea-7f9e3f2d9a3a",
"run": "echo 111"
},
"zIndex": 2
}
],
"edges": [
{
"shape": "data-processing-curve",
"inherit": "edge",
"connector": {
"name": "rounded",
"args": {
"radius": 10
}
},
"router": {
"name": "manhattan"
},
"attrs": {
"line": {
"strokeDasharray": "0"
}
},
"id": "39159699-26b7-4db8-99c0-9088be560a22",
"zIndex": -1,
"source": {
"cell": "on-push-81a68a8",
"port": "on-push-81a68a8-right"
},
"target": {
"cell": "job-18f4d4af",
"port": "job-18f4d4af-left"
}
},
{
"shape": "data-processing-curve",
"inherit": "edge",
"connector": {
"name": "rounded",
"args": {
"radius": 10
}
},
"router": {
"name": "manhattan"
},
"attrs": {
"line": {
"strokeWidth": 1,
"strokeDasharray": "3"
}
},
"id": "3c6f7387-74d5-4af1-a2f7-8520ed7b446e",
"zIndex": -1,
"source": {
"cell": "job-18f4d4af",
"port": "job-18f4d4af-bottom"
},
"target": {
"cell": "shell-992db95",
"port": "shell-992db95-top"
}
}
]
}
}'{}