generate interface and peer configuration filenames in backend only (#395)

This commit is contained in:
Christoph
2025-04-19 13:12:31 +02:00
parent a60feb7fc9
commit 6681dfa96f
14 changed files with 91 additions and 20 deletions

View File

@@ -1646,6 +1646,10 @@
"EnabledPeers": {
"type": "integer"
},
"Filename": {
"description": "the filename of the config file, for example: wg0.conf",
"type": "string"
},
"FirewallMark": {
"description": "a firewall mark",
"type": "integer"
@@ -1887,6 +1891,10 @@
"type": "string"
}
},
"Filename": {
"description": "the filename of the config file, for example: wg_peer_x.conf",
"type": "string"
},
"FirewallMark": {
"description": "a firewall mark",
"allOf": [

View File

@@ -88,6 +88,9 @@ definitions:
type: array
EnabledPeers:
type: integer
Filename:
description: 'the filename of the config file, for example: wg0.conf'
type: string
FirewallMark:
description: a firewall mark
type: integer
@@ -256,6 +259,9 @@ definitions:
items:
type: string
type: array
Filename:
description: 'the filename of the config file, for example: wg_peer_x.conf'
type: string
FirewallMark:
allOf:
- $ref: '#/definitions/model.ConfigOption-uint32'

View File

@@ -1531,6 +1531,13 @@
"type": "integer",
"readOnly": true
},
"Filename": {
"description": "Filename is the name of the config file for this interface.\nThis value is read only and is not settable by the user.",
"type": "string",
"maxLength": 21,
"readOnly": true,
"example": "wg0.conf"
},
"FirewallMark": {
"description": "FirewallMark is an optional firewall mark which is used to handle interface traffic.",
"type": "integer"
@@ -1799,6 +1806,13 @@
"type": "string"
}
},
"Filename": {
"description": "Filename is the name of the config file for this peer.\nThis value is read only and is not settable by the user.",
"type": "string",
"maxLength": 21,
"readOnly": true,
"example": "wg_peer_x.conf"
},
"FirewallMark": {
"description": "FirewallMark is an optional firewall mark which is used to handle peer traffic.",
"allOf": [

View File

@@ -87,6 +87,14 @@ definitions:
Only enabled peers are able to connect.
readOnly: true
type: integer
Filename:
description: |-
Filename is the name of the config file for this interface.
This value is read only and is not settable by the user.
example: wg0.conf
maxLength: 21
readOnly: true
type: string
FirewallMark:
description: FirewallMark is an optional firewall mark which is used to handle
interface traffic.
@@ -310,6 +318,14 @@ definitions:
items:
type: string
type: array
Filename:
description: |-
Filename is the name of the config file for this peer.
This value is read only and is not settable by the user.
example: wg_peer_x.conf
maxLength: 21
readOnly: true
type: string
FirewallMark:
allOf:
- $ref: '#/definitions/models.ConfigOption-uint32'