Skip to content

Commit

Permalink
Inital PTP events consumer
Browse files Browse the repository at this point in the history
  • Loading branch information
nocturnalastro committed Aug 13, 2024
1 parent fc149f1 commit d8b5277
Show file tree
Hide file tree
Showing 4 changed files with 73 additions and 0 deletions.
1 change: 1 addition & 0 deletions templates/ptp-events-consumer/READEME.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Deploys a consumer of PTP events fromt he ORAN API
48 changes: 48 additions & 0 deletions templates/ptp-events-consumer/deployment.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
apiVersion: apps/v1
kind: Deployment
metadata:
name: ptp-event-deployment
labels:
app: du-ptp-event-consumer
spec:
replicas: 1
selector:
matchLabels:
app: du-ptp-event-consumer
template:
metadata:
labels:
app: du-ptp-event-consumer
spec:
nodeSelector:
node-role.kubernetes.io/worker: ""
serviceAccountName: ptp-event-consumer-sa
containers:
- name: ptp-consumer
image: quay.io/jenchen/ptp-event-consumer:latest
args:
- "--local-api-addr=127.0.0.1:27017"
- "--api-path=/api/ocloudNotifications/v1/"
- "--api-addr=127.0.0.1:27017"
env:
- name: NODE_NAME
valueFrom:
fieldRef:
fieldPath: spec.nodeName
- name: NAME_SPACE
valueFrom:
fieldRef:
apiVersion: v1
fieldPath: metadata.namespace
- name: CONSUMER_PORT
value: "27017"
- name: CONSUMER_TYPE
value: "PTP"
- name: ENABLE_STATUS_CHECK
value: "true"
volumeMounts:
- name: pubsubstore
mountPath: /store
volumes:
- name: pubsubstore
emptyDir: {}
6 changes: 6 additions & 0 deletions templates/ptp-events-consumer/service-account.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
apiVersion: v1
kind: ServiceAccount
metadata:
name: ptp-event-consumer-sa
labels:
app: du-ptp-event-consumer
18 changes: 18 additions & 0 deletions templates/ptp-events-consumer/service.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
apiVersion: v1
kind: Service
metadata:
annotations:
prometheus.io/scrape: "true"
name: du-ptp-event-consumer-service
labels:
app: du-ptp-event-consumer
spec:
ports:
- name: sub-port
port: 27017
targetPort: http
selector:
app: test50
clusterIP: None
sessionAffinity: None
type: ClusterIP

0 comments on commit d8b5277

Please sign in to comment.