Compare commits

...

2 Commits

Author SHA1 Message Date
Ray Elliott 7c0481a960 various fixes 2020-09-04 14:23:11 +01:00
Ray Elliott 8d9df59d11 remove .com from wordpress url, reove allow-root optoins 2020-09-04 13:34:57 +01:00
1 changed files with 19 additions and 8 deletions

View File

@ -41,19 +41,23 @@ define( 'WP_DEBUG_LOG', true );
PHP
wp core install \
--path="$wp_path" \
--url="$domain".com \
--url="$domain" \
--title="$wp_title" \
--admin_user="$wp_user" \
--admin_password="$wp_pass" \
--admin_email="$wp_email"
fi
EOSSH
if [ -n "$wp_themes" ] ; then
printf "\nInstalling themes ..."
option='--activate'
for theme in $wp_themes ; do
echo " installing $theme ..."
wp theme install $theme "$option" --path="$wp_path" --allow-root
ssh -T $ssh << EOSSH
su "$user"
wp theme install $theme "$option" --path="$wp_path"
EOSSH
option=''
done
fi
@ -62,7 +66,10 @@ if [ -n "$wp_plugins" ] ; then
printf "\nInstalling plugins ..."
for plugin in $wp_plugins ; do
echo " installing $plugin ..."
wp plugin install $plugin --path="$wp_path" --allow-root
ssh -T $ssh << EOSSH
su "$user"
wp plugin install $plugin --path="$wp_path"
EOSSH
done
fi
@ -70,7 +77,10 @@ if [ -n "$wp_plugins_active" ] ; then
printf "\nInstalling plugins to activate ..."
for plugin in $wp_plugins_active ; do
echo " installing $plugin ..."
wp plugin install $plugin --activate --path="$wp_path" --allow-root
ssh -T $ssh << EOSSH
su "$user"
wp plugin install $plugin --activate --path="$wp_path"
EOSSH
done
fi
@ -78,13 +88,14 @@ if [ -n "$wp_plugins_active" ] ; then
printf "\nUninstalling plugins ..."
for plugin in $wp_plugins_uninstall ; do
echo " installing $plugin ..."
wp plugin deactivate $plugin --path="$wp_path" --allow-root
wp plugin uninstall $plugin --path="$wp_path" --allow-root
ssh -T $ssh << EOSSH
su "$user"
wp plugin deactivate $plugin --path="$wp_path"
wp plugin uninstall $plugin --path="$wp_path"
EOSSH
done
fi
EOSSH
config_path='/etc/apache2/sites-available/wordpress.conf'
ssh -T $ssh << EOSSH
if [ -n "$apache2_version" ] ; then