Use rsync instead of cp to copy header files

test
Eric Loyd 4 years ago
parent 1dd87e1c39
commit 475e5e83a8

@ -18,7 +18,7 @@ secondary=""
synconly="false" synconly="false"
syncname="sync" syncname="sync"
extraCmd="" extraCmd=""
cssDir="/usr/local/nagiosxi/html/includes/components/custom-includes/css/" cssDir="/usr/local/nagiosxi/html/includes/components/custom-includes/css"
hostname=`/bin/hostname` hostname=`/bin/hostname`
@ -73,7 +73,7 @@ do_primary() {
# Update header.css with proper gradient files # Update header.css with proper gradient files
if [ -r "${cssDir}/header.css.primary" -a -w "${cssDir}/header.css" ]; then if [ -r "${cssDir}/header.css.primary" -a -w "${cssDir}/header.css" ]; then
verbose "Copying local gradient files" verbose "Copying local gradient files"
cp ${cssDir}/header.css.primary ${cssDir}/header.css rsync ${cssDir}/header.css.primary ${cssDir}/header.css
fi fi
} }
@ -96,7 +96,7 @@ do_secondary() {
# Update header.css with proper gradient files # Update header.css with proper gradient files
if [ -r "${cssDir}/header.css.secondary" -a -w "${cssDir}/header.css" ]; then if [ -r "${cssDir}/header.css.secondary" -a -w "${cssDir}/header.css" ]; then
verbose "Copying local gradient files" verbose "Copying local gradient files"
cp ${cssDir}/header.css.secondary ${cssDir}/header.css rsync ${cssDir}/header.css.secondary ${cssDir}/header.css
fi fi
verbose "Ensuring that xi.key file has proper permissions" verbose "Ensuring that xi.key file has proper permissions"
chmod 0640 /usr/local/nagiosxi/var/keys/xi.key chmod 0640 /usr/local/nagiosxi/var/keys/xi.key

Loading…
Cancel
Save