mirror of https://github.com/OpenVidu/openvidu.git
openvidu-deployment: azure - Add support for additional install flags in all the deployments
parent
2de2920acf
commit
76a6f6c301
|
@ -159,6 +159,8 @@ param adminUsername string
|
||||||
@secure()
|
@secure()
|
||||||
param adminSshKey object
|
param adminSshKey object
|
||||||
|
|
||||||
|
param additionalInstallFlags string = ''
|
||||||
|
|
||||||
/*------------------------------------------- VARIABLES AND VALIDATIONS -------------------------------------------*/
|
/*------------------------------------------- VARIABLES AND VALIDATIONS -------------------------------------------*/
|
||||||
|
|
||||||
//Condition for ipValid if is filled
|
//Condition for ipValid if is filled
|
||||||
|
@ -263,6 +265,7 @@ var stringInterpolationParams = {
|
||||||
turnOwnPublicCertificate: turnOwnPublicCertificate
|
turnOwnPublicCertificate: turnOwnPublicCertificate
|
||||||
turnOwnPrivateCertificate: turnOwnPrivateCertificate
|
turnOwnPrivateCertificate: turnOwnPrivateCertificate
|
||||||
keyVaultName: keyVaultName
|
keyVaultName: keyVaultName
|
||||||
|
additionalInstallFlags: additionalInstallFlags
|
||||||
}
|
}
|
||||||
|
|
||||||
var installScriptTemplate = '''
|
var installScriptTemplate = '''
|
||||||
|
@ -334,6 +337,18 @@ COMMON_ARGS=(
|
||||||
"--livekit-api-secret=$LIVEKIT_API_SECRET"
|
"--livekit-api-secret=$LIVEKIT_API_SECRET"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# Include additional installer flags provided by the user
|
||||||
|
if [[ "${additionalInstallFlags}" != "" ]]; then
|
||||||
|
IFS=',' read -ra EXTRA_FLAGS <<< "${additionalInstallFlags}"
|
||||||
|
for extra_flag in "${EXTRA_FLAGS[@]}"; do
|
||||||
|
# Trim whitespace around each flag
|
||||||
|
extra_flag="$(echo -e "${extra_flag}" | sed -e 's/^[ \t]*//' -e 's/[ \t]*$//')"
|
||||||
|
if [[ "$extra_flag" != "" ]]; then
|
||||||
|
COMMON_ARGS+=("$extra_flag")
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
# Turn with TLS
|
# Turn with TLS
|
||||||
if [[ "${turnDomainName}" != '' ]]; then
|
if [[ "${turnDomainName}" != '' ]]; then
|
||||||
LIVEKIT_TURN_DOMAIN_NAME=$(/usr/local/bin/store_secret.sh save LIVEKIT-TURN-DOMAIN-NAME "${turnDomainName}")
|
LIVEKIT_TURN_DOMAIN_NAME=$(/usr/local/bin/store_secret.sh save LIVEKIT-TURN-DOMAIN-NAME "${turnDomainName}")
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -285,6 +285,28 @@
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "FLAGS",
|
||||||
|
"label": "(Optional) Additional Install Flags",
|
||||||
|
"elements": [
|
||||||
|
{
|
||||||
|
"name": "additionalInstallFlags",
|
||||||
|
"type": "Microsoft.Common.TextBox",
|
||||||
|
"label": "Additional Install Flags",
|
||||||
|
"subLabel": "Additional optional flags to pass to the OpenVidu installer (comma-separated, e.g., \"--flag1=value, --flag2\")",
|
||||||
|
"defaultValue": "",
|
||||||
|
"toolTip": "",
|
||||||
|
"constraints": {
|
||||||
|
"required": false,
|
||||||
|
"regex": "^[A-Za-z0-9, =_.\\-]*$",
|
||||||
|
"validationMessage": "Must be a comma-separated list of flags (for example, --flag=value, --bool-flag)",
|
||||||
|
"validations": []
|
||||||
|
},
|
||||||
|
"infoMessages": [],
|
||||||
|
"visible": true
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "parameters TURN",
|
"name": "parameters TURN",
|
||||||
"label": "(Optional) TURN server configuration with TLS",
|
"label": "(Optional) TURN server configuration with TLS",
|
||||||
|
@ -370,7 +392,8 @@
|
||||||
"adminUsername": "[steps('parameters INSTANCE').adminUsername]",
|
"adminUsername": "[steps('parameters INSTANCE').adminUsername]",
|
||||||
"adminSshKey": "[steps('parameters INSTANCE').adminSshKey]",
|
"adminSshKey": "[steps('parameters INSTANCE').adminSshKey]",
|
||||||
"storageAccountName": "[steps('parameters STORAGE').storageAccountName]",
|
"storageAccountName": "[steps('parameters STORAGE').storageAccountName]",
|
||||||
"containerName": "[steps('parameters STORAGE').containerName]"
|
"containerName": "[steps('parameters STORAGE').containerName]",
|
||||||
|
"additionalInstallFlags": "[steps('FLAGS').additionalInstallFlags]"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -293,6 +293,8 @@ param maxNumberOfMediaNodes int = 5
|
||||||
@description('Target CPU percentage to scale up or down')
|
@description('Target CPU percentage to scale up or down')
|
||||||
param scaleTargetCPU int = 50
|
param scaleTargetCPU int = 50
|
||||||
|
|
||||||
|
param additionalInstallFlags string = ''
|
||||||
|
|
||||||
/*------------------------------------------- VARIABLES AND VALIDATIONS -------------------------------------------*/
|
/*------------------------------------------- VARIABLES AND VALIDATIONS -------------------------------------------*/
|
||||||
|
|
||||||
var isEmptyIp = publicIpAddressObject.newOrExistingOrNone == 'none'
|
var isEmptyIp = publicIpAddressObject.newOrExistingOrNone == 'none'
|
||||||
|
@ -420,6 +422,7 @@ var stringInterpolationParamsMaster = {
|
||||||
openviduLicense: openviduLicense
|
openviduLicense: openviduLicense
|
||||||
rtcEngine: rtcEngine
|
rtcEngine: rtcEngine
|
||||||
keyVaultName: keyVaultName
|
keyVaultName: keyVaultName
|
||||||
|
additionalInstallFlags: additionalInstallFlags
|
||||||
}
|
}
|
||||||
|
|
||||||
var installScriptTemplateMaster = '''
|
var installScriptTemplateMaster = '''
|
||||||
|
@ -530,6 +533,17 @@ COMMON_ARGS=(
|
||||||
"--livekit-api-secret=$LIVEKIT_API_SECRET"
|
"--livekit-api-secret=$LIVEKIT_API_SECRET"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# Include additional installer flags provided by the user
|
||||||
|
if [[ "${additionalInstallFlags}" != "" ]]; then
|
||||||
|
IFS=',' read -ra EXTRA_FLAGS <<< "${additionalInstallFlags}"
|
||||||
|
for extra_flag in "${EXTRA_FLAGS[@]}"; do
|
||||||
|
# Trim whitespace around each flag
|
||||||
|
extra_flag="$(echo -e "${extra_flag}" | sed -e 's/^[ \t]*//' -e 's/[ \t]*$//')"
|
||||||
|
if [[ "$extra_flag" != "" ]]; then
|
||||||
|
COMMON_ARGS+=("$extra_flag")
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
# Turn with TLS
|
# Turn with TLS
|
||||||
if [[ "${turnDomainName}" != '' ]]; then
|
if [[ "${turnDomainName}" != '' ]]; then
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -458,6 +458,28 @@
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "FLAGS",
|
||||||
|
"label": "(Optional) Additional Install Flags",
|
||||||
|
"elements": [
|
||||||
|
{
|
||||||
|
"name": "additionalInstallFlags",
|
||||||
|
"type": "Microsoft.Common.TextBox",
|
||||||
|
"label": "Additional Install Flags",
|
||||||
|
"subLabel": "Additional optional flags to pass to the OpenVidu installer (comma-separated, e.g., \"--flag1=value, --flag2\")",
|
||||||
|
"defaultValue": "",
|
||||||
|
"toolTip": "",
|
||||||
|
"constraints": {
|
||||||
|
"required": false,
|
||||||
|
"regex": "^[A-Za-z0-9, =_.\\-]*$",
|
||||||
|
"validationMessage": "Must be a comma-separated list of flags (for example, --flag=value, --bool-flag)",
|
||||||
|
"validations": []
|
||||||
|
},
|
||||||
|
"infoMessages": [],
|
||||||
|
"visible": true
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "parameters TURN",
|
"name": "parameters TURN",
|
||||||
"label": "(Optional) TURN server configuration with TLS",
|
"label": "(Optional) TURN server configuration with TLS",
|
||||||
|
@ -552,7 +574,8 @@
|
||||||
"datetime": "[steps('parameters SCALING').datetime]",
|
"datetime": "[steps('parameters SCALING').datetime]",
|
||||||
"automationAccountName": "[steps('parameters SCALING').automationAccountName]",
|
"automationAccountName": "[steps('parameters SCALING').automationAccountName]",
|
||||||
"storageAccountName": "[steps('parameters STORAGE').storageAccountName]",
|
"storageAccountName": "[steps('parameters STORAGE').storageAccountName]",
|
||||||
"containerName": "[steps('parameters STORAGE').containerName]"
|
"containerName": "[steps('parameters STORAGE').containerName]",
|
||||||
|
"additionalInstallFlags": "[steps('FLAGS').additionalInstallFlags]"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -296,6 +296,8 @@ param maxNumberOfMediaNodes int = 5
|
||||||
@description('Target CPU percentage to scale up or down')
|
@description('Target CPU percentage to scale up or down')
|
||||||
param scaleTargetCPU int = 50
|
param scaleTargetCPU int = 50
|
||||||
|
|
||||||
|
param additionalInstallFlags string = ''
|
||||||
|
|
||||||
/*------------------------------------------- VARIABLES AND VALIDATIONS -------------------------------------------*/
|
/*------------------------------------------- VARIABLES AND VALIDATIONS -------------------------------------------*/
|
||||||
|
|
||||||
var masterNodeVMSettings = {
|
var masterNodeVMSettings = {
|
||||||
|
@ -436,6 +438,7 @@ var stringInterpolationParamsMaster1 = {
|
||||||
rtcEngine: rtcEngine
|
rtcEngine: rtcEngine
|
||||||
keyVaultName: keyVaultName
|
keyVaultName: keyVaultName
|
||||||
masterNodeNum: '1'
|
masterNodeNum: '1'
|
||||||
|
additionalInstallFlags: additionalInstallFlags
|
||||||
}
|
}
|
||||||
|
|
||||||
var stringInterpolationParamsMaster2 = {
|
var stringInterpolationParamsMaster2 = {
|
||||||
|
@ -452,6 +455,7 @@ var stringInterpolationParamsMaster2 = {
|
||||||
rtcEngine: rtcEngine
|
rtcEngine: rtcEngine
|
||||||
keyVaultName: keyVaultName
|
keyVaultName: keyVaultName
|
||||||
masterNodeNum: '2'
|
masterNodeNum: '2'
|
||||||
|
additionalInstallFlags: additionalInstallFlags
|
||||||
}
|
}
|
||||||
|
|
||||||
var stringInterpolationParamsMaster3 = {
|
var stringInterpolationParamsMaster3 = {
|
||||||
|
@ -468,6 +472,7 @@ var stringInterpolationParamsMaster3 = {
|
||||||
rtcEngine: rtcEngine
|
rtcEngine: rtcEngine
|
||||||
keyVaultName: keyVaultName
|
keyVaultName: keyVaultName
|
||||||
masterNodeNum: '3'
|
masterNodeNum: '3'
|
||||||
|
additionalInstallFlags: additionalInstallFlags
|
||||||
}
|
}
|
||||||
|
|
||||||
var stringInterpolationParamsMaster4 = {
|
var stringInterpolationParamsMaster4 = {
|
||||||
|
@ -484,6 +489,7 @@ var stringInterpolationParamsMaster4 = {
|
||||||
rtcEngine: rtcEngine
|
rtcEngine: rtcEngine
|
||||||
keyVaultName: keyVaultName
|
keyVaultName: keyVaultName
|
||||||
masterNodeNum: '4'
|
masterNodeNum: '4'
|
||||||
|
additionalInstallFlags: additionalInstallFlags
|
||||||
}
|
}
|
||||||
|
|
||||||
var installScriptTemplateMaster = '''
|
var installScriptTemplateMaster = '''
|
||||||
|
@ -662,6 +668,18 @@ COMMON_ARGS=(
|
||||||
"--livekit-api-secret=$LIVEKIT_API_SECRET"
|
"--livekit-api-secret=$LIVEKIT_API_SECRET"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# Include additional installer flags provided by the user
|
||||||
|
if [[ "${additionalInstallFlags}" != "" ]]; then
|
||||||
|
IFS=',' read -ra EXTRA_FLAGS <<< "${additionalInstallFlags}"
|
||||||
|
for extra_flag in "${EXTRA_FLAGS[@]}"; do
|
||||||
|
# Trim whitespace around each flag
|
||||||
|
extra_flag="$(echo -e "${extra_flag}" | sed -e 's/^[ \t]*//' -e 's/[ \t]*$//')"
|
||||||
|
if [[ "$extra_flag" != "" ]]; then
|
||||||
|
COMMON_ARGS+=("$extra_flag")
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
if [[ $LIVEKIT_TURN_DOMAIN_NAME != "" ]]; then
|
if [[ $LIVEKIT_TURN_DOMAIN_NAME != "" ]]; then
|
||||||
COMMON_ARGS+=("--turn-domain-name=$LIVEKIT_TURN_DOMAIN_NAME")
|
COMMON_ARGS+=("--turn-domain-name=$LIVEKIT_TURN_DOMAIN_NAME")
|
||||||
fi
|
fi
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -473,6 +473,28 @@
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "FLAGS",
|
||||||
|
"label": "(Optional) Additional Install Flags",
|
||||||
|
"elements": [
|
||||||
|
{
|
||||||
|
"name": "additionalInstallFlags",
|
||||||
|
"type": "Microsoft.Common.TextBox",
|
||||||
|
"label": "Additional Install Flags",
|
||||||
|
"subLabel": "Additional optional flags to pass to the OpenVidu installer (comma-separated, e.g., \"--flag1=value, --flag2\")",
|
||||||
|
"defaultValue": "",
|
||||||
|
"toolTip": "",
|
||||||
|
"constraints": {
|
||||||
|
"required": false,
|
||||||
|
"regex": "^[A-Za-z0-9, =_.\\-]*$",
|
||||||
|
"validationMessage": "Must be a comma-separated list of flags (for example, --flag=value, --bool-flag)",
|
||||||
|
"validations": []
|
||||||
|
},
|
||||||
|
"infoMessages": [],
|
||||||
|
"visible": true
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "parameters TURN",
|
"name": "parameters TURN",
|
||||||
"label": "(Optional) TURN server configuration with TLS",
|
"label": "(Optional) TURN server configuration with TLS",
|
||||||
|
@ -568,7 +590,8 @@
|
||||||
"datetime": "[steps('parameters SCALING').datetime]",
|
"datetime": "[steps('parameters SCALING').datetime]",
|
||||||
"automationAccountName": "[steps('parameters SCALING').automationAccountName]",
|
"automationAccountName": "[steps('parameters SCALING').automationAccountName]",
|
||||||
"storageAccountName": "[steps('parameters STORAGE').storageAccountName]",
|
"storageAccountName": "[steps('parameters STORAGE').storageAccountName]",
|
||||||
"containerName": "[steps('parameters STORAGE').containerName]"
|
"containerName": "[steps('parameters STORAGE').containerName]",
|
||||||
|
"additionalInstallFlags": "[steps('FLAGS').additionalInstallFlags]"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -170,6 +170,8 @@ param adminUsername string
|
||||||
@secure()
|
@secure()
|
||||||
param adminSshKey object
|
param adminSshKey object
|
||||||
|
|
||||||
|
param additionalInstallFlags string = ''
|
||||||
|
|
||||||
/*------------------------------------------- VARIABLES AND VALIDATIONS -------------------------------------------*/
|
/*------------------------------------------- VARIABLES AND VALIDATIONS -------------------------------------------*/
|
||||||
|
|
||||||
//Condition for ipValid if is filled
|
//Condition for ipValid if is filled
|
||||||
|
@ -276,6 +278,7 @@ var stringInterpolationParams = {
|
||||||
keyVaultName: keyVaultName
|
keyVaultName: keyVaultName
|
||||||
openviduLicense: openviduLicense
|
openviduLicense: openviduLicense
|
||||||
rtcEngine: rtcEngine
|
rtcEngine: rtcEngine
|
||||||
|
additionalInstallFlags: additionalInstallFlags
|
||||||
}
|
}
|
||||||
|
|
||||||
var installScriptTemplate = '''
|
var installScriptTemplate = '''
|
||||||
|
@ -350,6 +353,18 @@ COMMON_ARGS=(
|
||||||
"--livekit-api-secret=$LIVEKIT_API_SECRET"
|
"--livekit-api-secret=$LIVEKIT_API_SECRET"
|
||||||
)
|
)
|
||||||
|
|
||||||
|
# Include additional installer flags provided by the user
|
||||||
|
if [[ "${additionalInstallFlags}" != "" ]]; then
|
||||||
|
IFS=',' read -ra EXTRA_FLAGS <<< "${additionalInstallFlags}"
|
||||||
|
for extra_flag in "${EXTRA_FLAGS[@]}"; do
|
||||||
|
# Trim whitespace around each flag
|
||||||
|
extra_flag="$(echo -e "${extra_flag}" | sed -e 's/^[ \t]*//' -e 's/[ \t]*$//')"
|
||||||
|
if [[ "$extra_flag" != "" ]]; then
|
||||||
|
COMMON_ARGS+=("$extra_flag")
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
# Turn with TLS
|
# Turn with TLS
|
||||||
if [[ "${turnDomainName}" != '' ]]; then
|
if [[ "${turnDomainName}" != '' ]]; then
|
||||||
LIVEKIT_TURN_DOMAIN_NAME=$(/usr/local/bin/store_secret.sh save LIVEKIT-TURN-DOMAIN-NAME "${turnDomainName}")
|
LIVEKIT_TURN_DOMAIN_NAME=$(/usr/local/bin/store_secret.sh save LIVEKIT-TURN-DOMAIN-NAME "${turnDomainName}")
|
||||||
|
|
File diff suppressed because one or more lines are too long
|
@ -335,6 +335,28 @@
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
"name": "FLAGS",
|
||||||
|
"label": "(Optional) Additional Install Flags",
|
||||||
|
"elements": [
|
||||||
|
{
|
||||||
|
"name": "additionalInstallFlags",
|
||||||
|
"type": "Microsoft.Common.TextBox",
|
||||||
|
"label": "Additional Install Flags",
|
||||||
|
"subLabel": "Additional optional flags to pass to the OpenVidu installer (comma-separated, e.g., \"--flag1=value, --flag2\")",
|
||||||
|
"defaultValue": "",
|
||||||
|
"toolTip": "",
|
||||||
|
"constraints": {
|
||||||
|
"required": false,
|
||||||
|
"regex": "^[A-Za-z0-9, =_.\\-]*$",
|
||||||
|
"validationMessage": "Must be a comma-separated list of flags (for example, --flag=value, --bool-flag)",
|
||||||
|
"validations": []
|
||||||
|
},
|
||||||
|
"infoMessages": [],
|
||||||
|
"visible": true
|
||||||
|
}
|
||||||
|
]
|
||||||
|
},
|
||||||
{
|
{
|
||||||
"name": "parameters TURN",
|
"name": "parameters TURN",
|
||||||
"label": "(Optional) TURN server configuration with TLS",
|
"label": "(Optional) TURN server configuration with TLS",
|
||||||
|
@ -422,7 +444,8 @@
|
||||||
"adminUsername": "[steps('parameters INSTANCE').adminUsername]",
|
"adminUsername": "[steps('parameters INSTANCE').adminUsername]",
|
||||||
"adminSshKey": "[steps('parameters INSTANCE').adminSshKey]",
|
"adminSshKey": "[steps('parameters INSTANCE').adminSshKey]",
|
||||||
"storageAccountName": "[steps('parameters STORAGE').storageAccountName]",
|
"storageAccountName": "[steps('parameters STORAGE').storageAccountName]",
|
||||||
"containerName": "[steps('parameters STORAGE').containerName]"
|
"containerName": "[steps('parameters STORAGE').containerName]",
|
||||||
|
"additionalInstallFlags": "[steps('FLAGS').additionalInstallFlags]"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue