template pathing corrected

This commit is contained in:
James Tomasino 2018-12-12 15:12:38 -05:00
parent ff55e35d89
commit 2316d618a3
3 changed files with 3 additions and 3 deletions

View File

@ -22,7 +22,7 @@ if [ "$run_user" -eq 0 ]; then
mkdir -p "/home/${n}/ships"
ln -s "$path" "/home/${n}/ships/${s}"
# notify user by email
sed -e "s/username/${n}/g" -e "s/shipname/${s}/" /etc/newship.tmpl | sendmail "${n}" "tomasino"
sed -e "s/username/${n}/g" -e "s/shipname/${s}/" /etc/templates/newship.tmpl | sendmail "${n}" "tomasino"
else
owner=$(stat -c %U "$path")
printf "That ship or colony already exists and is owned by %s\\n" "$owner"

View File

@ -12,7 +12,7 @@ if [ "$run_user" -eq 0 ]; then
newpw=$(pwgen -1B 10)
pwcrypt=$(perl -e "print crypt('${newpw}', 'sa');")
useradd -m -G users,www-data -p "$pwcrypt" -s /bin/bash "${n}" || exit 1
sed -e "s/newusername/${n}/g" -e "s/newpassword/${newpw}/" /etc/welcomemail.tmpl | sendmail "${n}" "${e}" "tomasino"
sed -e "s/newusername/${n}/g" -e "s/newpassword/${newpw}/" /etc/templates/welcomemail.tmpl | sendmail "${n}" "${e}" "tomasino"
fi
if [ ! -z "${k}" ]; then
printf "%s\\n" "${k}" >> "/home/${n}/.ssh/authorized_keys"

View File

@ -36,7 +36,7 @@ if [ "$run_user" -eq 0 ]; then
file_html="/var/www/html/index.html"
log_html="/var/www/html/log/index.html"
web_header_html="${SCRIPTPATH}/../templates/webheader.tmpl"
web_header_html="/etc/templates/webheader.tmpl"
ships_html="/var/www/html/ships/index.html"
error_html="/var/www/html/error.html"
html_dir="/var/www/html"