diff --git a/system_setup/logon_script.sh b/system_setup/logon_script.sh index 823f061..b7bbc09 100755 --- a/system_setup/logon_script.sh +++ b/system_setup/logon_script.sh @@ -82,11 +82,14 @@ git config --global --add safe.directory /opt/sys_config # Pre check for old configuration parameters, will be removed in the future if [ ! -z "${CLIENT_SOFTWARE_DST}" ] || [ ! -z "${CLIENT_SOFTWARE_SRC}" ]; then elog_add " ====================" + elog_add "" elog_add "WARNING: Your company/setup has still CLIENT_SOFTWARE_DST or CLIENT_SOFTWARE_SRC set." elog_add "These parameters are obsolete and must be removed! The new parameters are CLIENT_SOFTWARE_CUST_DST and CLIENT_SOFTWARE_CUST_SRC" elog_add "as the software repository has been split into customer software and distributed software." elog_add "Please try to relog first. If this problem reoccures, contact your system admins to correct it." elog_add "Will continue with the new path. Press any key to continue." + elog_add "" + elog_add " ====================" read -n 1 -s -r fi @@ -126,7 +129,7 @@ else # Rule seems to be ok, executing script elog_add "Matching Sudo rule found." elog_add "" - elog_add "Running client software sync..." + elog_add "Running ${SYSCONFIGPATH}/system_setup/sync_client_software.sh" elog_add_command "/usr/bin/sudo -n --preserve-env ${SYSCONFIGPATH}/system_setup/sync_client_software.sh install $1" if [[ $RETNO -ne 0 ]]; then elog_add "Errorcode was $RETNO" @@ -137,9 +140,9 @@ else fi #Anyway run user scripts if existent -elog_add "Running all software scripts in user- context." +elog_add "Running scripts in user- context." #1. Run the scripts, that are delivered by the package maintainers -elog_add "Pre Installed scripts" +elog_add "Pre installed scripts" for DIR in $(ls -d ${SYSCONFIGPATH}/client_software/*/ | sort); # list directories in the form "/tmp/dirname/" do DIR=${DIR%*/} # remove the trailing "/" @@ -162,6 +165,8 @@ do elog_add " ====================" fi done +elog_add "Done running pre installed scripts" + #2. Run the scripts, that are delivered by the package maintainers # To run scripts, the tepository path must always be set right (but maybe empty, which is fine) if [ "${CLIENT_SOFTWARE_CUST_DST}" != "${SYSCONFIGPATH}/client_software_cust" ]; then @@ -169,7 +174,7 @@ if [ "${CLIENT_SOFTWARE_CUST_DST}" != "${SYSCONFIGPATH}/client_software_cust" ]; echo "Please relog and if the problem reoccures, contact your system admins to correct the Values." read -n 1 -s -r -p "Press any key to continue" else - elog_add "Company delivered scripts in ${CLIENT_SOFTWARE_CUST_DST}" + elog_add "Running company delivered scripts in ${CLIENT_SOFTWARE_CUST_DST}" for DIR in $(ls -d ${CLIENT_SOFTWARE_CUST_DST}/*/ | sort); # list directories in the form "/tmp/dirname/" do DIR=${DIR%*/} # remove the trailing "/" @@ -192,8 +197,9 @@ else elog_add " ====================" fi done - elog_add "Completed user scripts in software." + elog_add "Done running company scripts" fi +elog_add "Completed user scripts." elog_add "" # Remove unused flatpak user installed software and data diff --git a/system_setup/sync_client_software.sh b/system_setup/sync_client_software.sh index e2d887b..07701fd 100755 --- a/system_setup/sync_client_software.sh +++ b/system_setup/sync_client_software.sh @@ -142,9 +142,9 @@ if [[ ! -z "${DISTCONFIGPATH_SRC}" ]]; then fi fi -echo "Running all software scripts in admin- context." +echo "Running scripts in admin- context." # Run pre installed scripts in client_software -echo "Running pre installed scripts first." +echo "Running pre installed scripts in admin- context." for DIR in $(ls -d ${SYSCONFIGPATH}/client_software/*/ | sort); do DIR=${DIR%*/} # remove the trailing "/" if [[ "$2." != "." ]] && [[ "${DIR}" != *"$2"* ]]; then @@ -167,7 +167,7 @@ for DIR in $(ls -d ${SYSCONFIGPATH}/client_software/*/ | sort); do echo " ====================" fi done -echo "Sucessfully installed pre-defined software." +echo "Done running pre installed scripts in admin- context." echo # To run scripts, the repository path must always be set right (but maybe empty, which is fine) @@ -182,6 +182,7 @@ else if [[ -z "${CLIENT_SOFTWARE_CUST_SRC}" ]]; then echo "No customer software sync is defined, skipping sync" echo "${CLIENT_SOFTWARE_CUST_DST} with ${CLIENT_SOFTWARE_CUST_SRC}" + echo else echo "Syncing customer software repository ${CLIENT_SOFTWARE_CUST_DST}" # Create Directory if not existent @@ -207,7 +208,7 @@ else #Run customer setup if [ ! -z "${CLIENT_SOFTWARE_CUST_DST}" ]; then - echo "Running all software scripts in admin- context." + echo "Running all company scripts in user- context." for DIR in $(ls -d ${CLIENT_SOFTWARE_CUST_DST}/*/ | sort); do DIR=${DIR%*/} # remove the trailing "/" if [[ "$1." != "." ]] && [[ "${DIR}" != *"$1"* ]]; then @@ -230,6 +231,7 @@ else echo " ====================" fi done + echo "Done running all company scripts in user- context." fi fi