blob: 83fb84c9062fc6b6c0eafce962a88535b2fa4f9d [file] [log] [blame]
Zack Williams41513bf2018-07-07 20:08:35 -07001# Copyright 2017-present Open Networking Foundation
2#
3# Licensed under the Apache License, Version 2.0 (the "License");
4# you may not use this file except in compliance with the License.
5# You may obtain a copy of the License at
6#
7# http://www.apache.org/licenses/LICENSE-2.0
8#
9# Unless required by applicable law or agreed to in writing, software
10# distributed under the License is distributed on an "AS IS" BASIS,
11# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12# See the License for the specific language governing permissions and
13# limitations under the License.
Stephane Barbarie5e8d9e42018-02-07 16:15:05 -050014apiVersion: v1
15kind: Service
16metadata:
17 name: freeradius
Stephane Barbarie35595062018-02-08 08:34:39 -050018 namespace: voltha
Stephane Barbarie5e8d9e42018-02-07 16:15:05 -050019 labels:
20 name: freeradius
21spec:
22 clusterIP: None
23 ports:
24 - name: radius-auth
25 protocol: UDP
26 port: 1812
27 targetPort: 1812
28 - name: radius-acc
29 protocol: UDP
30 port: 1813
31 targetPort: 1813
32 - name: radius
33 port: 18120
34 targetPort: 18120
35 selector:
36 app: freeradius
37---
38apiVersion: apps/v1beta1
39kind: Deployment
40metadata:
41 name: freeradius
Stephane Barbarie35595062018-02-08 08:34:39 -050042 namespace: voltha
Stephane Barbarie5e8d9e42018-02-07 16:15:05 -050043spec:
44 replicas: 1
45 template:
46 metadata:
47 labels:
48 app: freeradius
49 annotations:
Stephane Barbarie2d4e07f2018-03-26 16:46:45 -040050 cni: "calico"
Stephane Barbarie5e8d9e42018-02-07 16:15:05 -050051 spec:
52 containers:
53 - name: freeradius
54 image: "marcelmaatkamp/freeradius"
55 env:
56 - name: POD_IP
57 valueFrom:
58 fieldRef:
59 fieldPath: status.podIP
60 - name: NAMESPACE
61 valueFrom:
62 fieldRef:
63 fieldPath: metadata.namespace
64 ports:
65 - containerPort: 1812
66 name: radauth-port
67 - containerPort: 1813
68 name: radacc-port
69 - containerPort: 18120
70 name: radius-port
71 volumeMounts:
72 - name: freeradius-config
73 mountPath: /etc/raddb/clients.conf
74 subPath: clients.conf
75 - name: freeradius-config
76 mountPath: /etc/raddb/users
77 subPath: users
78 volumes:
79 - name: freeradius-config
80 configMap:
81 name: freeradius-config