| # Copyright 2018 Google Inc. All Rights Reserved. |
| apiVersion: apps/v1 |
| kind: Deployment |
| metadata: |
| labels: |
| app: file-server |
| annotations: |
| imagetag: $IMAGETAG |
| buildtag: "$TAG" |
| name: file-server |
| spec: |
| replicas: 4 |
| selector: |
| matchLabels: |
| app: file-server |
| strategy: |
| rollingUpdate: |
| maxSurge: 2 |
| maxUnavailable: 0 |
| type: RollingUpdate |
| |
| template: |
| metadata: |
| labels: |
| app: file-server |
| spec: |
| containers: |
| - command: |
| - /opt/goma/bin/file_server |
| - --trace-project-id=$PROJECT_ID |
| - --redis-max-idle-conns=16 |
| - --redis-max-active-conns=32 |
| - --bucket=$CACHE_BUCKET_PREFIX-file-cache |
| name: file-server |
| image: gcr.io/$CONTAINER_PROJECT_ID/file-server:$IMAGETAG |
| ports: |
| - containerPort: 5050 |
| protocol: TCP |
| - containerPort: 8081 |
| protocol: TCP |
| resources: |
| limits: |
| cpu: 1000m |
| memory: 2048Mi |
| requests: |
| cpu: 500m |
| memory: 1024Mi |
| # following could be configured by PodPreset? |
| livenessProbe: |
| httpGet: |
| path: /healthz |
| port: 8081 |
| scheme: HTTP |
| initialDelaySeconds: 5 |
| periodSeconds: 5 |
| readinessProbe: |
| httpGet: |
| path: /healthz |
| port: 8081 |
| scheme: HTTP |
| initialDelaySeconds: 5 |
| periodSeconds: 5 |