mirror of
https://github.com/datarhei/core.git
synced 2025-09-26 20:11:29 +08:00
Fix omitting empty cleanup rules
This commit is contained in:
54
docs/docs.go
54
docs/docs.go
@@ -3597,7 +3597,7 @@ const docTemplate = `{
|
||||
"tags": [
|
||||
"v16.?.?"
|
||||
],
|
||||
"summary": "Add a new process",
|
||||
"summary": "Probe a process config",
|
||||
"operationId": "process-3-probe-config",
|
||||
"parameters": [
|
||||
{
|
||||
@@ -3632,6 +3632,58 @@ const docTemplate = `{
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/v3/process/validate": {
|
||||
"post": {
|
||||
"security": [
|
||||
{
|
||||
"ApiKeyAuth": []
|
||||
}
|
||||
],
|
||||
"description": "Probe a process to get a detailed stream information on the inputs.",
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"v16.?.?"
|
||||
],
|
||||
"summary": "Validate a process config",
|
||||
"operationId": "process-3-validate-config",
|
||||
"parameters": [
|
||||
{
|
||||
"description": "Process config",
|
||||
"name": "config",
|
||||
"in": "body",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/api.ProcessConfig"
|
||||
}
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/api.Probe"
|
||||
}
|
||||
},
|
||||
"400": {
|
||||
"description": "Bad Request",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/api.Error"
|
||||
}
|
||||
},
|
||||
"403": {
|
||||
"description": "Forbidden",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/api.Error"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/v3/process/{id}": {
|
||||
"get": {
|
||||
"security": [
|
||||
|
@@ -3590,7 +3590,7 @@
|
||||
"tags": [
|
||||
"v16.?.?"
|
||||
],
|
||||
"summary": "Add a new process",
|
||||
"summary": "Probe a process config",
|
||||
"operationId": "process-3-probe-config",
|
||||
"parameters": [
|
||||
{
|
||||
@@ -3625,6 +3625,58 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/v3/process/validate": {
|
||||
"post": {
|
||||
"security": [
|
||||
{
|
||||
"ApiKeyAuth": []
|
||||
}
|
||||
],
|
||||
"description": "Probe a process to get a detailed stream information on the inputs.",
|
||||
"consumes": [
|
||||
"application/json"
|
||||
],
|
||||
"produces": [
|
||||
"application/json"
|
||||
],
|
||||
"tags": [
|
||||
"v16.?.?"
|
||||
],
|
||||
"summary": "Validate a process config",
|
||||
"operationId": "process-3-validate-config",
|
||||
"parameters": [
|
||||
{
|
||||
"description": "Process config",
|
||||
"name": "config",
|
||||
"in": "body",
|
||||
"required": true,
|
||||
"schema": {
|
||||
"$ref": "#/definitions/api.ProcessConfig"
|
||||
}
|
||||
}
|
||||
],
|
||||
"responses": {
|
||||
"200": {
|
||||
"description": "OK",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/api.Probe"
|
||||
}
|
||||
},
|
||||
"400": {
|
||||
"description": "Bad Request",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/api.Error"
|
||||
}
|
||||
},
|
||||
"403": {
|
||||
"description": "Forbidden",
|
||||
"schema": {
|
||||
"$ref": "#/definitions/api.Error"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"/api/v3/process/{id}": {
|
||||
"get": {
|
||||
"security": [
|
||||
|
@@ -5964,7 +5964,40 @@ paths:
|
||||
$ref: '#/definitions/api.Error'
|
||||
security:
|
||||
- ApiKeyAuth: []
|
||||
summary: Add a new process
|
||||
summary: Probe a process config
|
||||
tags:
|
||||
- v16.?.?
|
||||
/api/v3/process/validate:
|
||||
post:
|
||||
consumes:
|
||||
- application/json
|
||||
description: Probe a process to get a detailed stream information on the inputs.
|
||||
operationId: process-3-validate-config
|
||||
parameters:
|
||||
- description: Process config
|
||||
in: body
|
||||
name: config
|
||||
required: true
|
||||
schema:
|
||||
$ref: '#/definitions/api.ProcessConfig'
|
||||
produces:
|
||||
- application/json
|
||||
responses:
|
||||
"200":
|
||||
description: OK
|
||||
schema:
|
||||
$ref: '#/definitions/api.Probe'
|
||||
"400":
|
||||
description: Bad Request
|
||||
schema:
|
||||
$ref: '#/definitions/api.Error'
|
||||
"403":
|
||||
description: Forbidden
|
||||
schema:
|
||||
$ref: '#/definitions/api.Error'
|
||||
security:
|
||||
- ApiKeyAuth: []
|
||||
summary: Validate a process config
|
||||
tags:
|
||||
- v16.?.?
|
||||
/api/v3/report/process:
|
||||
|
@@ -144,7 +144,7 @@ type ProcessConfigIO struct {
|
||||
ID string `json:"id"`
|
||||
Address string `json:"address" validate:"required" jsonschema:"minLength=1"`
|
||||
Options []string `json:"options"`
|
||||
Cleanup []ProcessConfigIOCleanup `json:"cleanup,omitempty"`
|
||||
Cleanup []ProcessConfigIOCleanup `json:"cleanup"`
|
||||
}
|
||||
|
||||
type ProcessConfigIOCleanup struct {
|
||||
|
@@ -303,6 +303,7 @@ func (h *ProcessHandler) Update(c echo.Context) error {
|
||||
process := api.ProcessConfig{
|
||||
ID: id,
|
||||
Owner: ctxuser,
|
||||
Domain: domain,
|
||||
Type: "ffmpeg",
|
||||
Autostart: true,
|
||||
}
|
||||
|
Reference in New Issue
Block a user