Install nginx on cPanel server Date Posted: 15-11-2017 cPanel is the widely used control panel to manage webhosting and it comes with apache as a default webserver. Nginx is fast webserver when compared to apache webserver. In this tutorial, we will explain on how to install nginx on cpanel server.… Continue Reading Install nginx on cPanel server

L1aravel 5.5 installation on VestaCP domain Date posted: 31-10-2017 Assumptions:- We assume you have the following server setup VestaCP Ubuntu 16.04 Nginx PHP >= 7.0.0 PHP modules OpenSSL, xml, PDO, Tokenizer and mbstring Installing Laravel Install composer apt-get install composer Download the Laravel installer using Composer: composer global require “laravel/installer”… Continue Reading Laravel installation on VestaCP account

Add Access Control Allow Origin Region(CORS) for fonts in NGINX? Date Posted: 02-10-2017 In this post, we will explain on how to allow cors (Cross Origin Region) for fonts on nginx. We may have seen the following on google chrome console or firefox firebug addon. No ‘Access-Control-Allow-Origin’ header is Prerequisites:… Continue Reading Allow Cross Origin Region(CORS) for Fonts in NGINX

Setting up different documentroot for subdirectory on nginx Date Posted: 24-09-2017 Nginx is a fastest webserver when compared to apache.  In this post, we are going to explain how to setup different documentroot for subdirectory. The maindomain documentroot will be /var/www/html and subdirectory folder documentroot /var/www/folder. Prerequisites: Nginx Webserver. If nginx… Continue Reading Setting up different documentroot for subdirectory on nginx

Add Access Control Allow Origin Region(CORS) in NGINX? Date Posted: 31-08-2017 In this post, we will explain on how to allow cors (Cross Origin Region) on nginx. We may have seen the following on google chrome console or firefox firebug addon. No ‘Access-Control-Allow-Origin’ header is Prerequisites: Nginx Webserver.  If nginx… Continue Reading Allow Cross Origin Region(CORS) in NGINX

WordPress post xmlrpc.php attack Prevention Date Posted: 17-07-2017 This post explains on how to prevent xmlrpc.php attack on wordpress website. If we seen below error or continuous POST request to xmlrpc.php on access log will be best way to identify attack. 2017/07/17 06:25:46 [error] 14858#14858: *411668 connect() to unix:/run/php/php7.0-fpm.sock failed… Continue Reading WordPress post xmlrpc.php attack Prevention

When you integrate angular2 with laravel on top of nginx, you may see empty page while accessing angular2 end point on browser. say http://server-ip/angularclient if you dig little deeper using inspect element, you may see 404 for all files(css,html,js,etc). You just need to verify the href base is as same… Continue Reading laravel and angular2 setup shows empty page on nginx

You might get not found error (404) when you access laravel API end points on nginx. To resolve this we need to add below rules in nginx.conf. Post that reload nginx conf. location @rewrite { rewrite ^/(.*)$ /index.php?_url=/$1; } location / { try_files $uri $uri/ @rewrite; } $ service nginx… Continue Reading Laravel route gives 404 error on nginx

Adding automatic extension (php) on nginx Date Posted:25-05-2017 Well, normally no one likes to expose the language written on their website. On apache, we will use .htaccess to autoadd the extension. In this post, we will show on how to autoadd the extension on nginx configuration. Incase, if nginx is… Continue Reading Adding automatic extension (php) on nginx

Codeigniter 404 error on nginx Date Posted:24-05-2017 Recently, we deployed a codeigniter application on one of our server and found that it shows 404 error when we try to access the custom urls(such as domain.tld/login, domain.tld/admin, domain.tld/dashboard). The same application works fine on Apache webserver. After a long research, we found… Continue Reading Codeigniter 404 error on nginx