<commit_before>---
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
  name: doppler-web
  namespace: default
spec:
  replicas: 1
  strategy:
    rollingUpdate:
      maxSurge: 1
      maxUnavailable: 0
    type: RollingUpdate
  template:
    metadata:
      labels:
        app: doppler
        component: web
        layer: application
      name: doppler-web
    spec:
      containers:
        - name: doppler-web
          env:
            - name: TRACE_AGENT_HOSTNAME
              valueFrom:
                fieldRef:
                  fieldPath: spec.nodeName
          envFrom:
            - configMapRef:
                name: doppler-environment
          image: 585031190124.dkr.ecr.us-east-1.amazonaws.com/doppler:staging
          imagePullPolicy: Always
          name: doppler-web
          ports:
            - containerPort: 8080
          resources:
            requests:
              cpu: 100m
              memory: 256Mi
            limits:
              memory: 500Mi
      dnsPolicy: ClusterFirst
      dnsConfig:
        options:
          - name: ndots
            value: "1"
      affinity:
        nodeAffinity:
          requiredDuringSchedulingIgnoredDuringExecution:
            nodeSelectorTerms:
              - matchExpressions:
                - key: tier
                  operator: In
                  values:
                    - foreground

---
apiVersion: v1
kind: Service
metadata:
  labels:
    app: doppler
    component: web
    layer: application
  name: doppler-web-internal
  namespace: default
spec:
  ports:
    - port: 8080
      protocol: TCP
      name: http
      targetPort: 8080
  selector:
    app: doppler
    layer: application
    component: web
  type: ClusterIP

---
apiVersion: extensions/v1beta1
kind: Ingress
metadata:
  name: doppler
  annotations:
    nginx.ingress.kubernetes.io/whitelist-source-range: "{{ cloudflareIpSourceRanges|join(',') }}"
spec:
  rules:
    - host: developers-staging.artsy.net
      http:
        paths:
          - path: /
            backend:
              serviceName: doppler-web-internal
              servicePort: http
<commit_msg>chore: update ./hokusai/staging.yml with k8s 1.18 definitions (#195)<commit_after>---
apiVersion: apps/v1
kind: Deployment
metadata:
  name: doppler-web
  namespace: default
  labels:
    app: doppler
    component: web
    layer: application
spec:
  replicas: 1
  strategy:
    rollingUpdate:
      maxSurge: 1
      maxUnavailable: 0
    type: RollingUpdate
  selector:
    matchLabels:
      app: doppler
      component: web
      layer: application
  template:
    metadata:
      labels:
        app: doppler
        component: web
        layer: application
      name: doppler-web
    spec:
      containers:
        - name: doppler-web
          env:
            - name: TRACE_AGENT_HOSTNAME
              valueFrom:
                fieldRef:
                  fieldPath: spec.nodeName
          envFrom:
            - configMapRef:
                name: doppler-environment
          image: 585031190124.dkr.ecr.us-east-1.amazonaws.com/doppler:staging
          imagePullPolicy: Always
          name: doppler-web
          ports:
            - containerPort: 8080
          resources:
            requests:
              cpu: 100m
              memory: 256Mi
            limits:
              memory: 500Mi
      dnsPolicy: ClusterFirst
      dnsConfig:
        options:
          - name: ndots
            value: "1"
      affinity:
        nodeAffinity:
          requiredDuringSchedulingIgnoredDuringExecution:
            nodeSelectorTerms:
              - matchExpressions:
                - key: tier
                  operator: In
                  values:
                    - foreground

---
apiVersion: v1
kind: Service
metadata:
  labels:
    app: doppler
    component: web
    layer: application
  name: doppler-web-internal
  namespace: default
spec:
  ports:
    - port: 8080
      protocol: TCP
      name: http
      targetPort: 8080
  selector:
    app: doppler
    layer: application
    component: web
  type: ClusterIP

---
apiVersion: networking.k8s.io/v1beta1
kind: Ingress
metadata:
  name: doppler
  annotations:
    nginx.ingress.kubernetes.io/whitelist-source-range: "{{ cloudflareIpSourceRanges|join(',') }}"
spec:
  ingressClassName: nginx
  rules:
    - host: developers-staging.artsy.net
      http:
        paths:
          - path: /
            pathType: Prefix
            backend:
              serviceName: doppler-web-internal
              servicePort: http

{'fraction_non_alphanumeric': 0.07389487574224764, 'fraction_numerical': 0.020453045964372113, 'mean_word_length': 1.595890410958904, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3262986', 'n_tokens_mistral': 1386, 'n_tokens_neox': 1281, 'n_words': 308}