blob: bfac617250607d2452fedec8e76f797a0ff30a77 [file] [log] [blame]
Miroslav Zagorac70230c62020-12-09 16:54:31 +01001#!/bin/sh
2#
3_ARG_HAPROXY="${1:-$(realpath -L ${PWD}/../../../haproxy)}"
4 _ARGS="-f ctx/haproxy.cfg"
5 _LOG_DIR="_logs"
Miroslav Zagorac1bd02222022-03-09 17:34:11 +01006 _LOG="${_LOG_DIR}/_log-$(basename "${0}" .sh)-$(date +%s)"
Miroslav Zagorac70230c62020-12-09 16:54:31 +01007
8
9test -x "${_ARG_HAPROXY}" || exit 1
10mkdir -p "${_LOG_DIR}" || exit 2
11
12echo "executing: ${_ARG_HAPROXY} ${_ARGS} > ${_LOG}"
13"${_ARG_HAPROXY}" ${_ARGS} >"${_LOG}" 2>&1