golang.org/x/build@v0.0.0-20240506185731-218518f32b70/cmd/gitmirror/deployment-serving.yaml (about)

     1  # Copyright 2022 The Go Authors. All rights reserved.
     2  # Use of this source code is governed by a BSD-style
     3  # license that can be found in the LICENSE file.
     4  
     5  apiVersion: apps/v1
     6  kind: Deployment
     7  metadata:
     8    namespace: prod
     9    name: gitmirror-serving-deployment
    10    labels:
    11      app: gitmirror-serving
    12  spec:
    13    strategy:
    14      rollingUpdate:
    15        maxUnavailable: 1
    16    replicas: 2
    17    selector:
    18      matchLabels:
    19        app: gitmirror-serving
    20    template:
    21      metadata:
    22        labels:
    23          app: gitmirror-serving
    24      spec:
    25        serviceAccountName: gitmirror
    26        volumes:
    27        - name: cache-volume
    28          emptyDir:
    29            medium: Memory
    30        containers:
    31        - name: gitmirror
    32          image: gcr.io/symbolic-datum-552/gitmirror:latest
    33          imagePullPolicy: Always
    34          env:
    35          - name: XDG_CACHE_HOME
    36            value: "/cache"
    37          command: ["/usr/bin/tini", "--", "/gitmirror", "-http=:8585", "-cachedir=/cache/gitmirror"]
    38          volumeMounts:
    39          - mountPath: /cache
    40            name: cache-volume
    41          ports:
    42          - containerPort: 8585
    43          livenessProbe:
    44            httpGet:
    45              path: /healthz
    46              port: 8585
    47            initialDelaySeconds: 600
    48            failureThreshold: 60
    49            periodSeconds: 10
    50          resources:
    51            requests:
    52              cpu: "2"
    53              memory: "5Gi"
    54            limits:
    55              cpu: "3"
    56              memory: "6Gi"