Read config from $XDG_CONFIG_HOME/letsencrypt/cli.ini.

This commit is contained in:
Jakub Warmuz 2015-07-03 14:38:09 +00:00
parent 108bd22ca3
commit c639673de5
No known key found for this signature in database
GPG key ID: 2A7BAD3A489B52EA

View file

@ -1,4 +1,5 @@
"""Let's Encrypt constants."""
import os
import logging
from acme import challenges
@ -8,7 +9,12 @@ SETUPTOOLS_PLUGINS_ENTRY_POINT = "letsencrypt.plugins"
"""Setuptools entry point group name for plugins."""
CLI_DEFAULTS = dict(
config_files=["/etc/letsencrypt/cli.ini"],
config_files=[
"/etc/letsencrypt/cli.ini",
# http://freedesktop.org/wiki/Software/xdg-user-dirs/
os.path.join(os.environ.get("XDG_CONFIG_HOME", "~/.config"),
"letsencrypt", "cli.ini"),
],
verbose_count=-(logging.WARNING / 10),
server="https://www.letsencrypt-demo.org/acme/new-reg",
rsa_key_size=2048,