fix: unlink the path before linking it again
This commit is contained in:
parent
0dca02cee6
commit
1d4672943d
2 changed files with 4 additions and 1 deletions
|
@ -66,6 +66,7 @@ def main() -> None:
|
|||
domain_key = os.path.join(args.output, f'{domain}/cert.pem.key')
|
||||
domain_pem = os.path.join(args.output, f'{domain}/cert.pem')
|
||||
|
||||
os.unlink(domain_key)
|
||||
os.link(private_key, domain_key)
|
||||
# TODO: add user/group to config
|
||||
shutil.chown(domain_key, 'acme', 'acme')
|
||||
|
@ -74,7 +75,9 @@ def main() -> None:
|
|||
all_pem = os.path.join(args.output, f'all/{domain}.pem')
|
||||
all_key = os.path.join(args.output, f'all/{domain}.pem.key')
|
||||
|
||||
os.unlink(all_pem)
|
||||
os.link(domain_pem, all_pem)
|
||||
os.unlink(all_key)
|
||||
os.link(domain_key, all_key)
|
||||
|
||||
if acquired:
|
||||
|
|
|
@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
|||
|
||||
[project]
|
||||
name = "nyacme"
|
||||
version = "0.1.8"
|
||||
version = "0.1.9"
|
||||
authors = [
|
||||
{name = "Patrycja Rosa", email = "python@ptrcnull.me"},
|
||||
]
|
||||
|
|
Loading…
Reference in a new issue