Add Yealink phone auto-provisioning server

This commit is contained in:
2026-03-11 07:05:10 +00:00
parent 33f48f92db
commit 4e9b5c7759

View File

@@ -0,0 +1,186 @@
apiVersion: v1
kind: ConfigMap
metadata:
name: yealink-provisioning
namespace: telephony
data:
# Common configuration for all Yealink phones
y000000000000.cfg: |
#!version:1.0.0.1
## Yealink Global Auto-Provisioning Config
## Applied to all Yealink phones that contact this server
## SIP Account 1
account.1.enable = 1
account.1.label = BlueJay
account.1.display_name = $MAC
account.1.sip_server.1.address = 10.0.56.207
account.1.sip_server.1.port = 5060
account.1.sip_server.1.transport_type = 0
account.1.sip_server.1.expires = 3600
account.1.codec.1.enable = 1
account.1.codec.1.payload_type = g722
account.1.codec.1.priority = 0
account.1.codec.2.enable = 1
account.1.codec.2.payload_type = PCMU
account.1.codec.2.priority = 1
account.1.codec.3.enable = 1
account.1.codec.3.payload_type = PCMA
account.1.codec.3.priority = 2
account.1.codec.4.enable = 1
account.1.codec.4.payload_type = opus
account.1.codec.4.priority = 3
## Network
network.dhcp_host_name =
network.vlan.internet_port_enable = 0
## Time
local_time.time_zone = -6
local_time.time_zone_name = United States-Central Time
local_time.ntp_server1 = 10.0.56.1
local_time.date_format = 1
local_time.time_format = 1
local_time.manual_ntp_srv_prior = 1
## Phone Settings
phone_setting.ring_type = Ring1.wav
features.power_saving.enable = 0
## Provisioning
auto_provision.server.url = https://10.0.56.207:8089/provision
auto_provision.repeat.enable = 1
auto_provision.repeat.minutes = 1440
# Per-phone configs (by MAC address)
# Extension 100 - Reception
ext100.cfg: |
#!version:1.0.0.1
account.1.enable = 1
account.1.label = Reception
account.1.display_name = Reception
account.1.auth_name = 100
account.1.user_name = 100
account.1.password = bluejay-ext-100
account.1.sip_server.1.address = 10.0.56.207
account.1.sip_server.1.port = 5060
account.1.sip_server.1.transport_type = 0
# Extension 101 - Office 1
ext101.cfg: |
#!version:1.0.0.1
account.1.enable = 1
account.1.label = Office 1
account.1.display_name = Office 1
account.1.auth_name = 101
account.1.user_name = 101
account.1.password = bluejay-ext-101
account.1.sip_server.1.address = 10.0.56.207
account.1.sip_server.1.port = 5060
account.1.sip_server.1.transport_type = 0
# Extension 102 - Office 2
ext102.cfg: |
#!version:1.0.0.1
account.1.enable = 1
account.1.label = Office 2
account.1.display_name = Office 2
account.1.auth_name = 102
account.1.user_name = 102
account.1.password = bluejay-ext-102
account.1.sip_server.1.address = 10.0.56.207
account.1.sip_server.1.port = 5060
account.1.sip_server.1.transport_type = 0
# Extension 103 - Office 3
ext103.cfg: |
#!version:1.0.0.1
account.1.enable = 1
account.1.label = Office 3
account.1.display_name = Office 3
account.1.auth_name = 103
account.1.user_name = 103
account.1.password = bluejay-ext-103
account.1.sip_server.1.address = 10.0.56.207
account.1.sip_server.1.port = 5060
account.1.sip_server.1.transport_type = 0
# nginx config for provisioning server
nginx.conf: |
server {
listen 8089 ssl;
ssl_certificate /etc/nginx/ssl/tls.crt;
ssl_certificate_key /etc/nginx/ssl/tls.key;
root /usr/share/nginx/html/provision;
autoindex off;
location /provision/ {
alias /usr/share/nginx/html/provision/;
default_type application/octet-stream;
}
}
---
apiVersion: apps/v1
kind: Deployment
metadata:
name: yealink-provision
namespace: telephony
labels:
app: yealink-provision
spec:
replicas: 1
selector:
matchLabels:
app: yealink-provision
template:
metadata:
labels:
app: yealink-provision
spec:
containers:
- name: nginx
image: nginx:alpine
ports:
- containerPort: 8089
protocol: TCP
volumeMounts:
- name: configs
mountPath: /usr/share/nginx/html/provision
- name: nginx-conf
mountPath: /etc/nginx/conf.d/default.conf
subPath: nginx.conf
resources:
requests:
cpu: 10m
memory: 16Mi
limits:
cpu: 100m
memory: 64Mi
volumes:
- name: configs
configMap:
name: yealink-provisioning
- name: nginx-conf
configMap:
name: yealink-provisioning
items:
- key: nginx.conf
path: nginx.conf
---
apiVersion: v1
kind: Service
metadata:
name: yealink-provision
namespace: telephony
labels:
app: yealink-provision
spec:
type: ClusterIP
selector:
app: yealink-provision
ports:
- name: https
port: 8089
targetPort: 8089
protocol: TCP