Fix master/slave certbot in bind
							parent
							
								
									de3e0e5b74
								
							
						
					
					
						commit
						78d82029f0
					
				|  | @ -20,8 +20,8 @@ key "certbot_challenge." { | ||||||
| 
 | 
 | ||||||
| // Let's Encrypt Challenge DNS-01 zone | // Let's Encrypt Challenge DNS-01 zone | ||||||
| zone "_acme-challenge.crans.org" { | zone "_acme-challenge.crans.org" { | ||||||
|  | 	{% if is_master -%} | ||||||
| 	type master; | 	type master; | ||||||
| 	file "bak._acme-challenge.crans.org"; |  | ||||||
| 	allow-transfer { | 	allow-transfer { | ||||||
| 		{% for ip in slaves_ipv4 -%} | 		{% for ip in slaves_ipv4 -%} | ||||||
| 		{{ ip }}; | 		{{ ip }}; | ||||||
|  | @ -30,6 +30,21 @@ zone "_acme-challenge.crans.org" { | ||||||
| 		{{ ip }}; | 		{{ ip }}; | ||||||
| 	{% endfor -%} | 	{% endfor -%} | ||||||
| 	}; | 	}; | ||||||
|  | 	notify yes; | ||||||
|  | 	{% else -%} | ||||||
|  | 	type slave; | ||||||
|  | 	masters { | ||||||
|  | 		{% for ip in masters_ipv4 -%} | ||||||
|  | 		{{ ip }}; | ||||||
|  | 		{% endfor -%} | ||||||
|  | 		{% for ip in masters_ipv6 -%} | ||||||
|  | 		{{ ip }}; | ||||||
|  | 	{% endfor -%} | ||||||
|  | 	}; | ||||||
|  | 	allow-transfer { "none"; }; | ||||||
|  | 	notify no; | ||||||
|  | 	{% endif -%} | ||||||
|  | 	file "bak.{{ zone }}"; | ||||||
| 	update-policy { | 	update-policy { | ||||||
| 		grant certbot_challenge. name _acme-challenge.crans.org txt; | 		grant certbot_challenge. name _acme-challenge.crans.org txt; | ||||||
| 	}; | 	}; | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue