diff --git a/deploy/checkServerStatus.sh b/deploy/checkServerStatus.sh index d038728d9131c9cda6a8b666166cb5ef1a2df79d..105c7bee71ea9fbe14426293f3c4cd5c5869dac4 100755 --- a/deploy/checkServerStatus.sh +++ b/deploy/checkServerStatus.sh @@ -20,6 +20,27 @@ then cd ~/MetaGer php artisan key:generate fi - # Falls notwendig Homestead Server intialisieren: - # - cd ~/ - # - vagrant box add --provider virtualbox laravel/homestead \ No newline at end of file +# Falls notwendig Homestead Server intialisieren: +if [ ! -d ~/Homestead ] +then + cd ~/ + # Wir brauchen unseren öffentlichen ssh Schlüssel: + if [ ! -d .ssh ] + then + mkdir .ssh + chmod 700 .ssh + fi + if [ ! -f .ssh/id_rsa.pub ] + then + cd .ssh + ssh-keygen -t rsa -N "" -f id_rsa + cd ~/ + fi + vagrant box add laravel/homestead + git clone https://github.com/laravel/homestead.git Homestead + cd Homestead/ + bash init.sh + mv -f "$path/deploy/Homestead.yaml" .homestead/ + vagrant up + echo "Your server is now running under http://localhost:8000" +fi