-#!/bin/sh
+#!/bin/bash
+# This file contains base functions for dehydrated hook scripts.
+# Please do not edit this file! It will be overwritten by package updates!
+# If you need to implement your own functions, take a look at
+# custom_functions file.
+
+# This function checks for per certificate hook scripts in hooks.d directory.
+# If not found, it executes global hook script instead.
deploy_cert() {
local DOMAIN="${1}" KEYFILE="${2}" CERTFILE="${3}" FULLCHAINFILE="${4}" CHAINFILE="${5}" TIMESTAMP="${6}"
if [[ -n "${HOOKS_D}" ]]; then
echo " + Hook: ${HANDLER}: Nothing to do..."
}
-# concat file atomic way
+# Function to concat files atomic way to avoid MITM problems
atomic_concat() {
local file=$1; shift
> $file.new