Update build scripts to reset file ownerships

This commit is contained in:
patvdv 2019-03-28 13:08:46 +01:00
parent 81f4dd6f54
commit 5de5f4404f
10 changed files with 31 additions and 9 deletions

View File

@ -5,6 +5,8 @@ HC_BIN="/opt/hc/bin/check_health.sh"
PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin" PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin"
# ------------------------- CONFIGURATION ends here --------------------------- # ------------------------- CONFIGURATION ends here ---------------------------
echo "INFO: starting post-install script ..." echo "INFO: starting post-install script ..."
# debian: reset ownerships
chown -R root:root /opt/hc /etc/opt/hc 2>/dev/null
# refresh symbolic FPATH links # refresh symbolic FPATH links
if [[ -x ${HC_BIN} ]] if [[ -x ${HC_BIN} ]]
then then

View File

@ -5,6 +5,8 @@ HC_BIN="/opt/hc/bin/check_health.sh"
PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin" PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin"
# ------------------------- CONFIGURATION ends here --------------------------- # ------------------------- CONFIGURATION ends here ---------------------------
echo "INFO: starting post-install script ..." echo "INFO: starting post-install script ..."
# debian: reset ownerships
chown -R root:root /opt/hc /etc/opt/hc 2>/dev/null
# refresh symbolic FPATH links # refresh symbolic FPATH links
if [[ -x ${HC_BIN} ]] if [[ -x ${HC_BIN} ]]
then then

View File

@ -5,6 +5,8 @@ HC_BIN="/opt/hc/bin/check_health.sh"
PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin" PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin"
# ------------------------- CONFIGURATION ends here --------------------------- # ------------------------- CONFIGURATION ends here ---------------------------
echo "INFO: starting post-install script ..." echo "INFO: starting post-install script ..."
# debian: reset ownerships
chown -R root:root /opt/hc /etc/opt/hc 2>/dev/null
# refresh symbolic FPATH links # refresh symbolic FPATH links
if [[ -x ${HC_BIN} ]] if [[ -x ${HC_BIN} ]]
then then

View File

@ -5,6 +5,8 @@ HC_BIN="/opt/hc/bin/check_health.sh"
PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin" PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin"
# ------------------------- CONFIGURATION ends here --------------------------- # ------------------------- CONFIGURATION ends here ---------------------------
echo "INFO: starting post-install script ..." echo "INFO: starting post-install script ..."
# debian: reset ownerships
chown -R root:root /opt/hc /etc/opt/hc 2>/dev/null
# refresh symbolic FPATH links # refresh symbolic FPATH links
if [[ -x ${HC_BIN} ]] if [[ -x ${HC_BIN} ]]
then then

View File

@ -5,6 +5,8 @@ HC_BIN="/opt/hc/bin/check_health.sh"
PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin" PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin"
# ------------------------- CONFIGURATION ends here --------------------------- # ------------------------- CONFIGURATION ends here ---------------------------
echo "INFO: starting post-install script ..." echo "INFO: starting post-install script ..."
# debian: reset ownerships
chown -R root:root /opt/hc /etc/opt/hc 2>/dev/null
# refresh symbolic FPATH links # refresh symbolic FPATH links
if [[ -x ${HC_BIN} ]] if [[ -x ${HC_BIN} ]]
then then

View File

@ -5,6 +5,8 @@ HC_BIN="/opt/hc/bin/check_health.sh"
PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin" PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin"
# ------------------------- CONFIGURATION ends here --------------------------- # ------------------------- CONFIGURATION ends here ---------------------------
echo "INFO: starting post-install script ..." echo "INFO: starting post-install script ..."
# debian: reset ownerships
chown -R root:root /opt/hc /etc/opt/hc 2>/dev/null
# refresh symbolic FPATH links # refresh symbolic FPATH links
if [[ -x ${HC_BIN} ]] if [[ -x ${HC_BIN} ]]
then then

View File

@ -5,6 +5,8 @@ HC_BIN="/opt/hc/bin/check_health.sh"
PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin" PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin"
# ------------------------- CONFIGURATION ends here --------------------------- # ------------------------- CONFIGURATION ends here ---------------------------
echo "INFO: starting post-install script ..." echo "INFO: starting post-install script ..."
# debian: reset ownerships
chown -R root:root /opt/hc /etc/opt/hc 2>/dev/null
# refresh symbolic FPATH links # refresh symbolic FPATH links
if [[ -x ${HC_BIN} ]] if [[ -x ${HC_BIN} ]]
then then

View File

@ -11,6 +11,10 @@ HC_BIN="/opt/hc/bin/check_health.sh"
PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin" PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin"
# ------------------------- CONFIGURATION ends here --------------------------- # ------------------------- CONFIGURATION ends here ---------------------------
echo "INFO: starting post-install script ..." echo "INFO: starting post-install script ..."
# debian: reset ownerships & permissions
chown -R root:root /opt/hc /etc/opt/hc 2>/dev/null
chown root:root /etc/logrotate.d/check_health 2>/dev/null
chmod 644 /etc/logrotate.d/check_health 2>/dev/null
# copy configuration files # copy configuration files
if [[ ! -f ${HC_ETC_DIR}/core/check_health.conf ]] if [[ ! -f ${HC_ETC_DIR}/core/check_health.conf ]]
then then

View File

@ -7,6 +7,8 @@ HC_BIN="/opt/hc/bin/check_health.sh"
PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin" PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin"
# ------------------------- CONFIGURATION ends here --------------------------- # ------------------------- CONFIGURATION ends here ---------------------------
echo "INFO: starting post-install script ..." echo "INFO: starting post-install script ..."
# debian: reset ownerships
chown -R root:root /opt/hc /etc/opt/hc 2>/dev/null
# copy plugin configuration file # copy plugin configuration file
if [[ ! -f ${HC_ETC_DIR}/core/providers/notify_eif.conf ]] if [[ ! -f ${HC_ETC_DIR}/core/providers/notify_eif.conf ]]
then then

View File

@ -7,6 +7,8 @@ HC_BIN="/opt/hc/bin/check_health.sh"
PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin" PATH="$PATH:/usr/bin:/etc:/usr/sbin:/usr/ucb:/usr/bin/X11:/sbin"
# ------------------------- CONFIGURATION ends here --------------------------- # ------------------------- CONFIGURATION ends here ---------------------------
echo "INFO: starting post-install script ..." echo "INFO: starting post-install script ..."
# debian: reset ownerships
chown -R root:root /opt/hc /etc/opt/hc 2>/dev/null
# copy plugin configuration file # copy plugin configuration file
if [[ ! -f ${HC_ETC_DIR}/core/providers/notify_sms.conf ]] if [[ ! -f ${HC_ETC_DIR}/core/providers/notify_sms.conf ]]
then then