Server Configuration

Read Installation on Shared Hosts


Either on a VPC or your own dedicated host is the best way to run phpVMS. As Laravel is designed, the /public directory is the directory that a vhost should be pointing to, since this is more secure. Having your own server will also allow you to setup a Redis queue and other optimizations to maximize your install's performance. Any serious VA that uses ACARS and other operations should be on a VPC.

The vhosts must point to the /public folder

These are only example configurations and may require some tweaking, depending on the software versions

<VirtualHost *:80>
    ServerAdmin webmaster@localhost
    ServerName yoursite.com
    ServiceAlias www.yoursite.com
    DocumentRoot /path/to/phpvms/public

    <Directory "/path/to/phpvms/public">
            Options FollowSymLinks
            ReWriteEngine On
    </Directory>

    ErrorLog ${APACHE_LOG_DIR}/error.log
    CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>

The paths below will need to be changed to what's correct for your server. You also need to have php-fpm installed. See the configuration file included with the nginx Docker config

server {
    listen 80 default_server;
    server_name phpvms.test;

    access_log /var/log/nginx/access.log;
    error_log /var/log/nginx/error.log;

    root /var/www/public;
    index index.php index.html index.htm;

    location / {
         try_files $uri $uri/ /index.php$is_args$args;
    }

    location ~ \.php$ {
        try_files $uri =404;
        fastcgi_split_path_info ^(.+\.php)(/.+)$;
        fastcgi_pass app:9000; # THIS DEPENDS ON YOUR SERVER AND MIGHT NEED TO CHANGE
        fastcgi_index index.php;
        fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
        include /etc/nginx/fastcgi_params;
    }

    location ~ /\.ht {
        deny all;
    }
}

Any resources about deploying Laravel applications apply. For example: