nginx code igniter remove index.php prefix

Objective

Remove the index.php prefix from your nginx code igniter instance.

Assumptions In your main nginx conf file you define how php is called (unix socket or ip:port) You will replace foo.example.com with whatever your domain name is The proper logging path will be defined per your system as opposed to the location i have . . . → Read More: nginx code igniter remove index.php prefix

nginx redirect single url

Objective

Using nginx redirect single url

Example

ORIGINAL URL:

REDIRECT TO:

nginx basic php location block example

nginx wordpress example

linux remove blank lines from file

To remove blank lines from a file on a unix or linux computer try this:

nginx logrotate script

nginx logrotate script

Create a new file at /etc/logrotate.d/nginx with contents:

Run Logrotate

nginx ssl pfx

This article will explain what to do with nginx ssl pfx.

First get the pfx file to your server. In this example we will be using a directory called “ssl” off of the nginx root (where nginx.conf is located).

From within the ssl folder, export the certificate:

Export the private key:

in the . . . → Read More: nginx ssl pfx

Install PHP APC with Nginx on Centos 6.2

Install PHP APC with Nginx on Centos 6.2

Install latest apc:

Move your old apc.ini to a safe location:

Create a new /etc/php.d/apc.ini (content below):

Copy the apc.php to your domains root directory to see it in action

If you are running Xcache which comes shipped with Centos 6.2 you will . . . → Read More: Install PHP APC with Nginx on Centos 6.2

nginx secure /user drupal

If you are not serving drupal out of a subdirectory use this config example:

If you are serving drupal out of a subdirectory /some_subdir and want to block access to the /user URI based on ip

nginx php centos6 howto

Remove previous php installation

Add the EPEL and REMI repos:

Install nginx prerequisites

Download nginx

Nginx configuration & installation:

PHP installation:

Edit Nginx configuration:

Create your web folder eg: /srv/www and change the owner of the folder:

– Create Directory

– Change ownership

Sample vhost configuration:

. . . → Read More: nginx php centos6 howto