mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2024-12-23 23:50:03 -06:00
krainstance: fix writing str to file
https://pagure.io/freeipa/issue/4985 Reviewed-By: Stanislav Laznicka <slaznick@redhat.com>
This commit is contained in:
parent
75d26e1f01
commit
276bef101b
@ -274,7 +274,7 @@ class KRAInstance(DogtagInstance):
|
||||
parentdir = os.path.dirname(paths.ADMIN_CERT_PATH)
|
||||
if not os.path.exists(parentdir):
|
||||
os.makedirs(parentdir)
|
||||
with open(paths.ADMIN_CERT_PATH, "w") as admin_path:
|
||||
with open(paths.ADMIN_CERT_PATH, "wb") as admin_path:
|
||||
admin_path.write(
|
||||
base64.b64encode(cert.public_bytes(x509.Encoding.DER))
|
||||
)
|
||||
|
Loading…
Reference in New Issue
Block a user