Skip to content

armgit / AiSOC

Public Imported from GitHub
0

Open-source AI Security Operations Center: alert fusion, LLM-agent triage, MITRE ATT&CK investigation, and a replayable decision ledger for every agent step. Self-hostable, runs with no API keys, MIT licensed. Ships an MCP server for Claude, Cursor and Continue.

2.7 KB
Raw Blame
{{- if .Values.coreApi.enabled }}
apiVersion: apps/v1
kind: Deployment
metadata:
  name: {{ include "aisoc.fullname" . }}-core-api
  labels:
    {{- include "aisoc.labels" . | nindent 4 }}
    app.kubernetes.io/component: core-api
spec:
  replicas: {{ .Values.coreApi.replicaCount }}
  selector:
    matchLabels:
      {{- include "aisoc.selectorLabels" . | nindent 6 }}
      app.kubernetes.io/component: core-api
  template:
    metadata:
      labels:
        {{- include "aisoc.selectorLabels" . | nindent 8 }}
        app.kubernetes.io/component: core-api
    spec:
      containers:
        - name: core-api
          image: "{{ .Values.coreApi.image.repository }}:{{ .Values.coreApi.image.tag }}"
          imagePullPolicy: {{ .Values.coreApi.image.pullPolicy }}
          ports:
            - name: http
              containerPort: 8000
              protocol: TCP
          env:
            - name: LOG_LEVEL
              value: {{ .Values.coreApi.env.LOG_LEVEL }}
            - name: ENVIRONMENT
              value: {{ .Values.global.environment }}
          {{- if .Values.coreApi.envFrom }}
          envFrom:
            {{- toYaml .Values.coreApi.envFrom | nindent 12 }}
          {{- end }}
          livenessProbe:
            httpGet:
              path: /health
              port: http
            initialDelaySeconds: 30
            periodSeconds: 10
          readinessProbe:
            httpGet:
              path: /health
              port: http
            initialDelaySeconds: 5
            periodSeconds: 5
          resources:
            {{- toYaml .Values.coreApi.resources | nindent 12 }}
---
apiVersion: v1
kind: Service
metadata:
  name: {{ include "aisoc.fullname" . }}-core-api
  labels:
    {{- include "aisoc.labels" . | nindent 4 }}
    app.kubernetes.io/component: core-api
spec:
  type: {{ .Values.coreApi.service.type }}
  ports:
    - port: {{ .Values.coreApi.service.port }}
      targetPort: http
      protocol: TCP
      name: http
  selector:
    {{- include "aisoc.selectorLabels" . | nindent 4 }}
    app.kubernetes.io/component: core-api
{{- if .Values.coreApi.autoscaling.enabled }}
---
apiVersion: autoscaling/v2
kind: HorizontalPodAutoscaler
metadata:
  name: {{ include "aisoc.fullname" . }}-core-api
spec:
  scaleTargetRef:
    apiVersion: apps/v1
    kind: Deployment
    name: {{ include "aisoc.fullname" . }}-core-api
  minReplicas: {{ .Values.coreApi.autoscaling.minReplicas }}
  maxReplicas: {{ .Values.coreApi.autoscaling.maxReplicas }}
  metrics:
    - type: Resource
      resource:
        name: cpu
        target:
          type: Utilization
          averageUtilization: {{ .Values.coreApi.autoscaling.targetCPUUtilizationPercentage }}
{{- end }}
{{- end }}