Skip to content
Permalink
Browse files
New Language: Keepalived configure file (#2417)
Co-authored-by: RunDevelopment <mitchi5000.ms@googlemail.com>
  • Loading branch information
dev-itsheng and RunDevelopment committed Oct 3, 2021
1 parent a80a68b commit d908e45781c6c09e51c29a8fc04e3a22b987826d

Large diffs are not rendered by default.

@@ -713,6 +713,10 @@
"title": "Julia",
"owner": "cdagnino"
},
"keepalived": {
"title": "Keepalived Configure",
"owner": "dev-itsheng"
},
"keyman": {
"title": "Keyman",
"owner": "mcdurdin"

Some generated files are not rendered by default. Learn more.

Some generated files are not rendered by default. Learn more.

@@ -0,0 +1,130 @@
<h2>A example from keepalived document</h2>
<pre><code>
# Configuration File for keepalived
global_defs {
notification_email {
admin@domain.com
0633225522@domain.com
}
notification_email_from keepalived@domain.com
smtp_server 192.168.200.20
smtp_connect_timeout 30
router_id LVS_MAIN
}

# VRRP Instances definitions
vrrp_instance VI_1 {
state MASTER
interface eth0
virtual_router_id 51
priority 150
advert_int 1
authentication {
auth_type PASS
auth_pass k@l!ve1
}
virtual_ipaddress {
192.168.200.10
192.168.200.11
}
}
vrrp_instance VI_2 {
state MASTER
interface eth1
virtual_router_id 52
priority 150
advert_int 1
authentication {
auth_type PASS
auth_pass k@l!ve2
}
virtual_ipaddress {
192.168.100.10
}
}
vrrp_instance VI_3 {
state BACKUP
interface eth0
virtual_router_id 53
priority 100
advert_int 1
authentication {
auth_type PASS
auth_pass k@l!ve3
}
virtual_ipaddress {
192.168.200.12
192.168.200.13
}
}
vrrp_instance VI_4 {
state BACKUP
interface eth1
virtual_router_id 54
priority 100
advert_int 1
authentication {
auth_type PASS
auth_pass k@l!ve4
}
virtual_ipaddress {
192.168.100.11
}
}
# Virtual Servers definitions
virtual_server 192.168.200.10 80 {
delay_loop 30
lb_algo wrr
lb_kind NAT
persistence_timeout 50
protocol TCP
sorry_server 192.168.100.100 80
real_server 192.168.100.2 80 {
weight 2
HTTP_GET {
url {
path /testurl/test.jsp
digest ec90a42b99ea9a2f5ecbe213ac9eba03
}
url {
path /testurl2/test.jsp
digest 640205b7b0fc66c1ea91c463fac6334c
}
connect_timeout 3
retry 3
delay_before_retry 2
}
}
real_server 192.168.100.3 80 {
weight 1
HTTP_GET {
url {
path /testurl/test.jsp
digest 640205b7b0fc66c1ea91c463fac6334c
}
connect_timeout 3
retry 3
delay_before_retry 2
}
}
}
virtual_server 192.168.200.12 443 {
delay_loop 20
lb_algo rr
lb_kind NAT
persistence_timeout 360
protocol TCP
real_server 192.168.100.2 443 {
weight 1
TCP_CHECK {
connect_timeout 3
}
}
real_server 192.168.100.3 443 {
weight 1
TCP_CHECK {
connect_timeout 3
}
}
}
</code></pre>
@@ -22,4 +22,5 @@ <h2>Server Block</h2>
location / {
proxy_pass http://127.0.0.1:8080;
}
}</code></pre>
}
</code></pre>
@@ -124,6 +124,7 @@
"jsonp": "JSONP",
"jsstacktrace": "JS stack trace",
"js-templates": "JS Templates",
"keepalived": "Keepalived Configure",
"kts": "Kotlin Script",
"kt": "Kotlin",
"kumir": "KuMir (КуМир)",

0 comments on commit d908e45

Please sign in to comment.