-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathsample-app.yaml
51 lines (48 loc) · 1.01 KB
/
sample-app.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
apiVersion: serving.knative.dev/v1
kind: Service
metadata:
name: sample-app
spec:
template:
metadata:
annotations:
# For testing purposes set request-per-second to 1 to force scaling
autoscaling.knative.dev/target: "1"
autoscaling.knative.dev/metric: "rps"
labels:
service: "ksample"
spec:
containers:
- image: nginx:stable
ports:
- containerPort: 80
volumeMounts:
- name: config
mountPath: "/etc/nginx"
readOnly: true
volumes:
- name: config
configMap:
name: nginx-config
items:
- key: "nginx.conf"
path: "nginx.conf"
---
apiVersion: v1
kind: ConfigMap
metadata:
name: nginx-config
data:
nginx.conf: |
worker_processes 1;
events {
worker_connections 1024;
}
http {
server {
listen 80;
location / {
return 200 'Hello world from initium-platform!';
}
}
}