-
Notifications
You must be signed in to change notification settings - Fork 0
/
ingress-envoy.yaml
145 lines (145 loc) · 4.09 KB
/
ingress-envoy.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
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
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
node:
cluster: test-chute
id: ingress-envoy
cluster_manager:
outlier_detection:
event_log_path: "/logs/outlier"
static_resources:
listeners:
- address:
socket_address:
address: 0.0.0.0
port_value: 6379
listener_filters:
- name: "envoy.listener.tls_inspector"
filter_chains:
- filter_chain_match:
server_names: ["redis1"]
tls_context:
common_tls_context:
tls_certificate_sds_secret_configs:
- name: server_cert
sds_config:
api_config_source:
api_type: GRPC
grpc_services:
envoy_grpc:
cluster_name: chute
validation_context_sds_secret_config:
name: redis1_validation
sds_config:
api_config_source:
api_type: GRPC
grpc_services:
envoy_grpc:
cluster_name: chute
filters:
- name: envoy.tcp_proxy
typed_config:
"@type": type.googleapis.com/envoy.config.filter.network.tcp_proxy.v2.TcpProxy
stat_prefix: ingress_envoy
cluster: redis1
- filter_chain_match:
server_names: ["redis2"]
tls_context:
common_tls_context:
tls_certificate_sds_secret_configs:
- name: server_cert
sds_config:
api_config_source:
api_type: GRPC
grpc_services:
envoy_grpc:
cluster_name: chute
validation_context_sds_secret_config:
name: redis2_validation
sds_config:
api_config_source:
api_type: GRPC
grpc_services:
envoy_grpc:
cluster_name: chute
filters:
- name: envoy.redis_proxy
typed_config:
"@type": type.googleapis.com/envoy.config.filter.network.redis_proxy.v2.RedisProxy
stat_prefix: ingress_envoy
prefix_routes:
routes:
- prefix: "1:"
cluster: redis1
- prefix: "2:"
cluster: redis2
catch_all_route:
cluster: redis2
settings:
op_timeout: 5s
enable_hashtagging: true
clusters:
- name: chute
connect_timeout: 1s
type: strict_dns
http2_protocol_options: {}
upstream_connection_options:
tcp_keepalive:
keepalive_time: 300
load_assignment:
cluster_name: chute
endpoints:
- lb_endpoints:
- endpoint:
address:
socket_address:
address: chute
port_value: 18000
- name: redis1
connect_timeout: 5s
type: strict_dns
lb_policy: MAGLEV
load_assignment:
cluster_name: redis1
endpoints:
- lb_endpoints:
- endpoint:
address:
socket_address:
address: redis1
port_value: 6379
- name: redis2
connect_timeout: 5s
type: strict_dns
respect_dns_ttl: true
lb_policy: MAGLEV
common_lb_config:
consistent_hashing_lb_config:
use_hostname_for_hashing: true
# health_checks:
# interval: 1s
# timeout: 0.5s
# healthy_threshold: 1
# unhealthy_threshold: 5
# event_log_path: "/logs/health"
# custom_health_check:
# name: envoy.health_checkers.redis
# outlier_detection:
load_assignment:
cluster_name: redis2
endpoints:
- lb_endpoints:
- endpoint:
address:
socket_address:
address: redis2
port_value: 6379
- lb_endpoints:
- endpoint:
address:
socket_address:
address: redis1
port_value: 6379
admin:
access_log_path: "/dev/null"
address:
socket_address:
address: 0.0.0.0
port_value: 8001