mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
Always expect subdomain xmpp-upload.domain.net.
This subdomain will be part of Letsencrypt certificate so it MUST be defined in DNS zone otherwise certificate renewal will fail.
This commit is contained in:
parent
e633c8351b
commit
c6e8bb5d26
3 changed files with 6 additions and 1 deletions
|
@ -192,7 +192,7 @@ authorityKeyIdentifier=keyid,issuer
|
|||
basicConstraints = CA:FALSE
|
||||
keyUsage = nonRepudiation, digitalSignature, keyEncipherment
|
||||
|
||||
subjectAltName=DNS:yunohost.org,DNS:www.yunohost.org,DNS:ns.yunohost.org
|
||||
subjectAltName=DNS:yunohost.org,DNS:www.yunohost.org,DNS:ns.yunohost.org,DNS:xmpp-upload.yunohost.org
|
||||
|
||||
[ v3_ca ]
|
||||
|
||||
|
|
|
@ -639,6 +639,9 @@ def _prepare_certificate_signing_request(domain, key_file, output_folder):
|
|||
# Set the domain
|
||||
csr.get_subject().CN = domain
|
||||
|
||||
# Include xmpp-upload subdomain as subject alternate names
|
||||
csr.add_extensions([crypto.X509Extension("subjectAltName", False, "DNS:xmpp-upload." + domain)])
|
||||
|
||||
# Set the key
|
||||
with open(key_file, 'rt') as f:
|
||||
key = crypto.load_privatekey(crypto.FILETYPE_PEM, f.read())
|
||||
|
|
|
@ -412,6 +412,7 @@ def _build_dns_conf(domain, ttl=3600):
|
|||
{"type": "CNAME", "name": "muc", "value": "@", "ttl": 3600},
|
||||
{"type": "CNAME", "name": "pubsub", "value": "@", "ttl": 3600},
|
||||
{"type": "CNAME", "name": "vjud", "value": "@", "ttl": 3600}
|
||||
{"type": "CNAME", "name": "xmpp-upload", "value": "@", "ttl": 3600}
|
||||
],
|
||||
"mail": [
|
||||
{"type": "MX", "name": "@", "value": "10 domain.tld.", "ttl": 3600},
|
||||
|
@ -453,6 +454,7 @@ def _build_dns_conf(domain, ttl=3600):
|
|||
["muc", ttl, "CNAME", "@"],
|
||||
["pubsub", ttl, "CNAME", "@"],
|
||||
["vjud", ttl, "CNAME", "@"],
|
||||
["xmpp-upload", ttl, "CNAME", "@"],
|
||||
]
|
||||
|
||||
# SPF record
|
||||
|
|
Loading…
Add table
Reference in a new issue