forked from kapicorp/kapitan-reference
-
Notifications
You must be signed in to change notification settings - Fork 0
/
echo-server.yml
126 lines (114 loc) · 3 KB
/
echo-server.yml
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
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
parameters:
components:
# configures the manifest generator
echo-server:
# Application from which to source defaults
application: microservices
# Basic settings
image: jmalloc/echo-server
pull_policy: Always
init_containers:
busybox:
image: docker pull busybox
command:
- echo "test"
env:
NODENAME:
fieldRef:
fieldPath: spec.nodeName
# Resource constraints
resources:
requests:
memory: 1G
limits:
memory: 1G
# Networking
service:
type: LoadBalancer
ports:
http:
container_port: 8080
internal:
container_port: 8081
# One or many network policies
network_policies:
default:
ingress:
- from:
- podSelector:
matchLabels:
role: frontend
ports:
- protocol: TCP
port: 6379
# Additional containers
additional_containers:
nginx:
image: nginx
ports:
nginx:
service_port: 80
config_maps:
config:
mount: /etc/nginx/conf.d/nginx.conf
subPath: nginx.conf
# Healthchecks definitions
healthcheck:
liveness:
type: http
port: http
httpHeaders:
- name: Host
value: www.google.com
path: /_health
timeout_seconds: 3
readiness:
type: http
port: http
path: /_ready
timeout_seconds: 5
# Configs and Secrets definitions
secrets:
secret:
data:
encoded_secret:
value: my_secret
b64_encode: true
better_secret:
value: ?{base64:targets/${target_name}/password||randomstr|base64}
config_maps:
config:
mount: /opt/echo-service/echo-service.conf
subPath: echo-service.conf
versioned: true
data:
echo-service.conf:
template: "components/echo-server/echo-server.conf.j2"
values:
example: true
nginx.conf:
value: |
server {
listen 80;
server_name localhost;
location / {
proxy_pass http://localhost:8080/;
}
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}
}
simple_config:
value: "not mounted"
# configures the ingress generator
ingresses:
global:
paths:
- backend:
service:
name: echo-server
port:
number: 80
path: /echo/*
pathType: Prefix