Skip to content

Conversation

@StefanLobbenmeierObjego

Fix #37

@StefanLobbenmeierObjego
Copy link
Author

Since it is unlikely the maintainer merges this / they seem to be inactive in this repo I went ahead and pushed to my own docker hub:

docker.io/stefanlobbenmeierobjego/sendgrid-stats-exporter:add-reputation

Also in case anyone ever needs it, this is a Kubernetes deployment if you do not want to configure prometheus directly but need to work with labels, feel free to reuse it, publishing it as https://unlicense.org here:

apiVersion: apps/v1
kind: Deployment
metadata:
  name: sendgrid-stats-exporter
  labels:
    app: objego
    service: sendgrid-stats-exporter
spec:
  selector:
    matchLabels:
      app: objego
      service: sendgrid-stats-exporter
  template:
    metadata:
      labels:
        app: objego
        service: sendgrid-stats-exporter
      annotations:
        "k8s.grafana.com/scrape": "true"
        "k8s.grafana.com/metrics.portNumber": "9154"
        "k8s.grafana.com/metrics.path": "/metrics"
    spec:
      containers:
        - name: sendgrid-stats-exporter
          image: docker.io/stefanlobbenmeierobjego/sendgrid-stats-exporter:add-reputation
          imagePullPolicy: Always
          env:
            - name: DISABLE_EXPORTER_METRICS
              value: "true"
          envFrom:
            - secretRef:
                name: sendgrid-stats-exporter-secret
          ports:
            - containerPort: 9154
          resources:
            requests:
              cpu: "50m"
              memory: "10Mi"
            limits:
              memory: "10Mi"
          startupProbe:
            httpGet:
              path: /-/healthy
              port: 9154
            initialDelaySeconds: 1
            periodSeconds: 1
            failureThreshold: 20
          readinessProbe:
            httpGet:
              path: /-/healthy
              port: 9154
            periodSeconds: 10
            failureThreshold: 3
          livenessProbe:
            httpGet:
              path: /-/healthy
              port: 9154
            periodSeconds: 10
            failureThreshold: 9

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Extract account reputation from /v3/user/account

1 participant