docker-mailserver/target/scripts
Brennan Kinney e807631a76
refactor: acme.json extraction (#2274)
Split into scoped commits with messages if further details are needed, view those via the associated PR :)

**Commit Summary:**

**`check-for-changes.sh`**

- Prevent `SSL_DOMAIN` silently skipping when value has wildcard prefix `*.` (_at least this was known as a bugfix when originally committed in linked PR_).
- Improved inlined docs for maintainers.
- Additional logging for debugging.

**`helper-functions.sh:_extract_certs_from_acme`**:

- Fail if the input arg (_`$CERT_DOMAIN`, aka the FQDN_) provided for extraction is empty.
- Use `$CERT_DOMAIN` in place of `$HOSTNAME` and `$1` for a consistent value (_previously could mismatch, eg with `SSL_DOMAIN` defined_).
- The conditional is now only for handling extraction failure (_key or cert value is missing from extraction_).
- Log an actual warning or success (debug) based on outcome.
- Don't use `SSL_DOMAIN` with wildcard value for the `mkdir` letsencrypt directory name (_wildcard prefix `*.` is first stripped instead_).

**`acme_extract`** (_new python utility for `acme.json` handling_):

- Extracted out into a python script that can be treated as a utility in the `$PATH` like other helper scripts. It can now be used and optionally tested directly instead of via `helper-functions.sh`.
-Made compatible with Python 3, as Python 2 is EOL and no longer in newer versions of Debian.
2021-11-04 09:28:40 +13:00
..
startup chore: Refactor setup-stack.sh case SSL_TYPE=letsencrypt (#2278) 2021-11-03 09:12:33 +13:00
check-for-changes.sh refactor: acme.json extraction (#2274) 2021-11-04 09:28:40 +13:00
fail2ban-wrapper.sh Final Migration Step (#6) 2021-01-16 10:16:05 +01:00
helper-functions.sh refactor: acme.json extraction (#2274) 2021-11-04 09:28:40 +13:00
postfix-wrapper.sh setup.sh: docker_container first, then fall back to docker_image (#2134) 2021-09-06 10:13:12 +00:00
postsrsd-wrapper.sh HOSTNAME and DOMAINNAME setting improvements (#2175) 2021-09-12 02:20:16 +12:00
quota-warning.sh Final Migration Step (#6) 2021-01-16 10:16:05 +01:00
start-mailserver.sh Add missing SA variables (#2283) 2021-11-02 11:51:36 +01:00
update-check.sh Update check (#1951) 2021-05-19 21:18:06 +02:00