I am very new to Wordpress / Roots.io / nginx so I would like to apologize in advance for my stupidity.
I have spent a couple days trying to figure this out and I clearly have a gap in my understanding of how this all works.
I am trying to install Wordpress onto a subdomain that I am hosting separately from my domain, via a DreamHost DreamCompute instance (Ubuntu 16.04). I am setting up everything using Trellis and trying to acclimate myself towards Wordpress best practices. I am also using Bedrock / Sage.
So I finally successfully got through all of the steps of setting up Trellis, from Development >> Deployment, but I cannot figure out why it is not working on my production site. (By successful I mean I received no errors via vagrant or otherwise).
*Replaced hostname with blog.example.com / blog.example.dev for clarity
My development site works flawlessly (blog.example.dev), but my production site seems to not be serving any requests (blog.example.com). By this I mean, when I go to blog.example.com or its IP address I am told the page is not working and that it did not send any data. This makes me think there is a problem with how nginx is setup, but clear guess work on my part.
All of the files seem to be in the right location (/srv/www/blog.example.com/current/web) and my nginx conf file seems to be in order:
Ansible managed: /vagrant/roles/wordpress-setup/templates/wordpress-site.conf.j2 modified on 2016-08-06 20:54:59 by vagrant on blog
server {
listen 80;server_name blog.example.com ;
access_log /srv/www/blog.example.com/logs/access.log;
error_log /srv/www/blog.example.com/logs/error.log;
root /srv/www/blog.example.com/current/web;
index index.php index.htm index.html;
charset utf-8;
add_header Fastcgi-Cache $upstream_cache_status;
include acme-challenge-location.conf;
include includes.d/blog.example.com/*.conf;
include wordpress.conf;
location ~ .php$ {
try_files $uri =404;
error_page 404 /index.php;
include fastcgi_params; fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name; fastcgi_param DOCUMENT_ROOT $realpath_root; fastcgi_pass unix:/var/run/php-fpm-wordpress.sock;
}
}
server {
listen 80;
server_name www.blog.example.com;
include acme-challenge-location.conf;
location / { return 301 $scheme://blog.example.com$request_uri; }
}
The only possibly relevant difference between the development and the production servers, as far as I can tell, is that /srv/www/blog.example.com/current/web is a static location on the development server but it is a relative location (shortcut) on the production server to the most reason deployment (/srv/www/blog.example.com/releases/20160807142536).
I have rebuilt the instance multiple times trying various site configurations, but I can’t seem to pinpoint where I am going wrong.
Again, I am sorry if this is a really stupid mistake, but I appreciate any assistance.
Thank you so much for your time and help!