mirror of
https://github.com/alexbelgium/hassio-addons.git
synced 2026-03-25 23:41:45 +01:00
Merge pull request #2466 from alexbelgium/codex/limit-interface-name-to-15-characters
Limit qBittorrent VPN interface names to 15 characters
This commit is contained in:
@@ -61,6 +61,10 @@ interface_name="$(basename "${wireguard_config}" .conf)"
|
||||
if [[ -z "${interface_name}" ]]; then
|
||||
interface_name='wg0'
|
||||
fi
|
||||
if [[ ${#interface_name} -gt 15 ]]; then
|
||||
bashio::log.warning "WireGuard interface name '${interface_name}' exceeds 15 characters; truncating to '${interface_name:0:15}'."
|
||||
interface_name="${interface_name:0:15}"
|
||||
fi
|
||||
|
||||
wireguard_runtime_config="${WIREGUARD_STATE_DIR}/${interface_name}.conf"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user