Loading charts/meep-loc-serv/templates/ingress.yaml +1 −2 Original line number Diff line number Diff line {{- if .Values.ingress.enabled -}} {{- $serviceName := .Values.service.name -}} {{- $serviceName := include "meep-loc-serv.fullname" . -}} {{- $servicePort := .Values.service.port -}} {{- $path := .Values.ingress.path -}} apiVersion: extensions/v1beta1 kind: Ingress metadata: Loading charts/meep-loc-serv/templates/service.yaml +1 −1 Original line number Diff line number Diff line apiVersion: v1 kind: Service metadata: name: {{ .Values.service.name }} name: {{ template "meep-loc-serv.fullname" . }} labels: app: {{ template "meep-loc-serv.name" . }} chart: {{ template "meep-loc-serv.chart" . }} Loading charts/meep-loc-serv/values-template.yaml +0 −5 Original line number Diff line number Diff line Loading @@ -28,11 +28,6 @@ image: {{- end}} service: {{- if .IsMepService }} name: meep-loc-serv-{{.MepName}} {{- else }} name: meep-loc-serv {{- end }} type: ClusterIP port: 80 Loading go-apps/meep-loc-serv/sbi/loc-serv-sbi.go +15 −5 Original line number Diff line number Diff line Loading @@ -44,6 +44,7 @@ type SbiCfg struct { type LocServSbi struct { sandboxName string localityEnabled bool locality map[string]bool mqLocal *mq.MsgQueue handlerId int Loading Loading @@ -73,10 +74,15 @@ func Init(cfg SbiCfg) (err error) { sbi.cleanUpCB = cfg.CleanUpCb // Fill locality map if len(cfg.Locality) > 0 { sbi.locality = make(map[string]bool) for _, locality := range cfg.Locality { sbi.locality[locality] = true } sbi.localityEnabled = true } else { sbi.localityEnabled = false } // Create message queue sbi.mqLocal, err = mq.NewMsgQueue(mq.GetLocalName(sbi.sandboxName), moduleName, sbi.sandboxName, cfg.RedisAddr) Loading Loading @@ -404,6 +410,10 @@ func isUeConnected(name string) bool { } func isInLocality(zone string) bool { _, found := sbi.locality[zone] return found if sbi.localityEnabled { if _, found := sbi.locality[zone]; !found { return false } } return true } Loading
charts/meep-loc-serv/templates/ingress.yaml +1 −2 Original line number Diff line number Diff line {{- if .Values.ingress.enabled -}} {{- $serviceName := .Values.service.name -}} {{- $serviceName := include "meep-loc-serv.fullname" . -}} {{- $servicePort := .Values.service.port -}} {{- $path := .Values.ingress.path -}} apiVersion: extensions/v1beta1 kind: Ingress metadata: Loading
charts/meep-loc-serv/templates/service.yaml +1 −1 Original line number Diff line number Diff line apiVersion: v1 kind: Service metadata: name: {{ .Values.service.name }} name: {{ template "meep-loc-serv.fullname" . }} labels: app: {{ template "meep-loc-serv.name" . }} chart: {{ template "meep-loc-serv.chart" . }} Loading
charts/meep-loc-serv/values-template.yaml +0 −5 Original line number Diff line number Diff line Loading @@ -28,11 +28,6 @@ image: {{- end}} service: {{- if .IsMepService }} name: meep-loc-serv-{{.MepName}} {{- else }} name: meep-loc-serv {{- end }} type: ClusterIP port: 80 Loading
go-apps/meep-loc-serv/sbi/loc-serv-sbi.go +15 −5 Original line number Diff line number Diff line Loading @@ -44,6 +44,7 @@ type SbiCfg struct { type LocServSbi struct { sandboxName string localityEnabled bool locality map[string]bool mqLocal *mq.MsgQueue handlerId int Loading Loading @@ -73,10 +74,15 @@ func Init(cfg SbiCfg) (err error) { sbi.cleanUpCB = cfg.CleanUpCb // Fill locality map if len(cfg.Locality) > 0 { sbi.locality = make(map[string]bool) for _, locality := range cfg.Locality { sbi.locality[locality] = true } sbi.localityEnabled = true } else { sbi.localityEnabled = false } // Create message queue sbi.mqLocal, err = mq.NewMsgQueue(mq.GetLocalName(sbi.sandboxName), moduleName, sbi.sandboxName, cfg.RedisAddr) Loading Loading @@ -404,6 +410,10 @@ func isUeConnected(name string) bool { } func isInLocality(zone string) bool { _, found := sbi.locality[zone] return found if sbi.localityEnabled { if _, found := sbi.locality[zone]; !found { return false } } return true }