After fixing a problem related to Vagrant that would not share the vagrant folder, now I have these two bugs:
- The server returns a 503 Service Unavailable error. Even if I just place a simple PHP file with some
echo. So it doesn't look like related to the code but to the environment. I am using Windows 10, VirtualBox 5.1.22 and Vagrant 1.9.7. In the Vagrantfile I selected Apache as the web server but it looks the the scripts/environment.sh file starts the nginx server, like it doesn't care about what server I have chosen. In any case, even if I disable the execution of the environment.sh file, the error persists. The vagrant installation doesn't output any error. The vhost config looks like this:
<VirtualHost *:80>
ServerAdmin webmaster@localhost
ServerName 192.168.29.29.xip.io
ServerAlias flarum.dev
DocumentRoot /vagrant
<Directory /vagrant>
Options -Indexes +FollowSymLinks +MultiViews
AllowOverride All
Require all granted
<FilesMatch \.php$>
# Change this "proxy:unix:/path/to/fpm.socket"
# if using a Unix socket
SetHandler "proxy:fcgi://127.0.0.1:9000"
</FilesMatch>
</Directory>
ErrorLog ${APACHE_LOG_DIR}/192.168.29.29.xip.io-error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/192.168.29.29.xip.io-access.log combined
</VirtualHost>
<VirtualHost *:443>
ServerAdmin webmaster@localhost
ServerName 192.168.29.29.xip.io
ServerAlias flarum.dev
DocumentRoot /vagrant
<Directory /vagrant>
Options -Indexes +FollowSymLinks +MultiViews
AllowOverride All
Require all granted
<FilesMatch \.php$>
# Change this "proxy:unix:/path/to/fpm.socket"
# if using a Unix socket
SetHandler "proxy:fcgi://127.0.0.1:9000"
</FilesMatch>
</Directory>
ErrorLog ${APACHE_LOG_DIR}/192.168.29.29.xip.io-error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/192.168.29.29.xip.io-access.log combined
SSLEngine on
SSLCertificateFile /etc/ssl/xip.io/xip.io.crt
SSLCertificateKeyFile /etc/ssl/xip.io/xip.io.key
<FilesMatch "\.(cgi|shtml|phtml|php)$">
SSLOptions +StdEnvVars
</FilesMatch>
BrowserMatch "MSIE [2-6]" \
nokeepalive ssl-unclean-shutdown \
downgrade-1.0 force-response-1.0
# MSIE 7 and newer should be able to use keepalive
BrowserMatch "MSIE [17-9]" ssl-unclean-shutdown
</VirtualHost>
I can see that Apache are PHP is running
When trying to install Flarum, PHP fails with this error: ``. This method doesn't exist indeed, in the master branch. I guess this has to be fixed on GIT where the code looks like messed up a bit. This is where it stops
==> Vaprobash: nginx: unrecognized service
==> Vaprobash: Do not run Composer as root/super user! See https://getcomposer.org
/root for details
==> Vaprobash: Loading composer repositories with package information
==> Vaprobash: Installing dependencies (including require-dev) from lock file
==> Vaprobash: Nothing to install or update
==> Vaprobash: Generating autoload files
==> Vaprobash: Do not run Composer as root/super user! See https://getcomposer.org
/root for details
==> Vaprobash: Generating autoload files
==> Vaprobash: PHP Fatal error: Uncaught Error: Call to undefined method Flarum\C
onsole\Server::fromSite() in /vagrant/flarum:16
==> Vaprobash: Stack trace:
==> Vaprobash: #0 {main}
==> Vaprobash: thrown in /vagrant/flarum on line 16
The SSH command responded with a non-zero exit status. Vagrant
assumes that this means the command failed. The output for this command
should be in the log above. Please read the output to determine what
went wrong.