forked from SemanticBeeng/seldoncloudflow
-
Notifications
You must be signed in to change notification settings - Fork 0
/
tfserving.yaml
executable file
·86 lines (86 loc) · 2.14 KB
/
tfserving.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
apiVersion: apps/v1
kind: Deployment
metadata:
name: fraudtfflow
labels:
app: fraudtfflow
spec:
replicas: 20
selector:
matchLabels:
app: fraudtfflow
strategy:
type: RollingUpdate
template:
metadata:
labels:
app: fraudtfflow
spec:
containers:
- name: serving
image: tensorflow/serving:1.14.0
imagePullPolicy: Always
ports:
- containerPort: 8500
name: grpc
protocol: TCP
- containerPort: 8501
name: http
protocol: TCP
readinessProbe:
tcpSocket:
port: http
initialDelaySeconds: 15
timeoutSeconds: 1
livenessProbe:
initialDelaySeconds: 30
periodSeconds: 30
tcpSocket:
port: htttp
resources:
limits:
cpu: "2"
memory: 2Gi
requests:
cpu: "1"
memory: 1Gi
env:
- name: "AWS_REGION"
value: "eu-west-1"
- name: "S3_REGION"
value: "eu-west-1"
- name: "S3_ENDPOINT"
value: "s3.eu-west-1.amazonaws.com"
- name: "S3_USE_HTTPS"
value: "1"
- name: "S3_VERIFY_SSL"
value: "1"
- name: "AWS_ACCESS_KEY_ID"
valueFrom: { secretKeyRef: { name: "s3-credentials", key: "accessKey" } }
- name: "AWS_SECRET_ACCESS_KEY"
valueFrom: { secretKeyRef: { name: "s3-credentials", key: "secretKey" } }
- name: "MODEL_BASE_PATH"
value: "s3://fdp-killrweather-data/kubeflow/fraud_detection/model"
- name: "MODEL_NAME"
value: "fraud"
volumes:
- name: secret-volume
secret:
secretName: s3-credentials
---
apiVersion: v1
kind: Service
metadata:
name: fraudtfflow
spec:
selector:
app: fraudtfflow
ports:
- name: grpc
protocol: TCP
port: 8500
targetPort: 8500
- name: http
protocol: TCP
port: 8501
targetPort: 8501