apiVersion: apps/v1
kind: Deployment
metadata:
  name: subnet-manager
  namespace: subnet-manager
  labels:
    app: subnet-manager
spec:
  selector:
    matchLabels:
      app: subnet-manager
  replicas: 1
  strategy:
    type: RollingUpdate
  template:
    metadata:
      labels:
        app: subnet-manager
    spec:
      hostNetwork: true
      containers:
        - name: opensm-service
          image: 'localhost/opensm-service:latest'
          imagePullPolicy: Never
          volumeMounts:
            - mountPath: /var/cache/opensm
              name: opensm-cache
            - mountPath: /var/log
              name: opensm-logs
          resources:
            limits:
              memory: "10Gi"
          securityContext:
            privileged: true
      volumes:
        - name: opensm-cache
          hostPath:
            path: /var/cache/opensm
            type: Directory
        - name: opensm-logs
          hostPath:
            path: /var/log
            type: Directory