347
edits
Changes
no edit summary
===Overview===
<p>
</p>
<p>
<pre>/usr/share/nginx/html</pre>
<div id="unzip">
In order to unzip the file, unzip must first be installed on the server. If it is not type:
<pre>aptidude install unzip</pre>
</div>
Then, unzip the file by typing:
<pre>/etc/nginx/sites-available/www</pre>
<div id="index.php>
In this file add ''index.php'' to the line shown below (shown with ''index.php'' added already).
<pre>index index.html index.htm index.php</pre>
</div>
Finally, the ''www'' file needs a location for SQLbuddy. Type:
<pre>cd /etc/nginx/sites-available</pre>
and open the ''www'' file.
Then, add this block of code below the current locations to set up a new location on the server for SQLbuddy:
<pre>
location ~ /sqlbuddy/.*\.php$ {
try_files $uri =404;
include fastcgi_params;
fastcgi_pass php5-fpm-sock;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_intercept_errors on;
}
</pre>
Reload NGINX:
<pre>/etc/init.d/nginx reload</pre>
Sqlbuddy should now be able to be accessed by typing in ''yourservername/sqlbuddy'' into the browser.
</p>
==phpMyAdmin==
===Overview===
<p>
The interface phpMyAdmin is actually one of the most popular web server database interface tools. Unfortunately, this comes with the downside of being the most common target for hackers making it a much larger security vulnerability than SQLbuddy. Also, it is not quite as lightweight, meaning it is slightly slower (not really noticeably with small queries though). But what it lacks in those departments, it makes up in sheer user friendliness. It is very easy to use this interface to manipulate a database without even really knowing any SQL (something that should NOT be indulged in by someone writing code, but it still makes manipulations easy). If SQL is the way to go for you, the SQL editor will highlight the syntax intelligibly to make it easier to read and spot errors. The choice really depends on your needs: quick and nimble without unneeded bells and whistles or slightly slower with heavy user interface.
</p>
===Installation===
<p>
This is pretty much a repeat from above, so this time we'll use a slightly different method to show how it works. Go to http://www.phpmyadmin.net/ and right click on ''Download''. Then click on the selection that will copy the link to the clipboard (''copy link address'' for Google Chrome). Now go to the following location in the server and remain there for the rest of the installation:
<pre>/usr/share/nginx/html</pre>
Use the command [[This Is Your Brain On Informatics: Linux Commands|wget]] and paste the link address into command line after it.
Now unzip the file (again, this will need to be [[#unzip|installed]] if it has not been already.
<pre>
unzip phpMyAdmin-4.1.5-all-languages.zip
mv phpMyAdmin-4.1.5-all-languages.zip phpMyAdmin
rm -rf phpMyAdmin-4.1.5-all-languages.zip
</pre>
Also, the type of index file that [[This Is Your Brain On Informatics: NGINX|NGINX]] recognizes will need to be changed so that it recognizes [[#index.php|index.php]] if it has not been done so already.
And lastly, we need to make a location for phpMyAdmin just as for SQLbuddy. Type:
<pre>cd /etc/nginx/sites-available</pre>
and open the ''www'' file.
Then, add this block of code below the current locations to set up a new location on the server for SQLbuddy:
<pre>
location ~ /phpMyAdmin/.*\.php$ {
try_files $uri =404;
include fastcgi_params;
fastcgi_pass php5-fpm-sock;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
fastcgi_intercept_errors on;
}
</pre>
Reload NGINX:
<pre>/etc/init.d/nginx reload</pre>
phpMyAdmin should now be able to be accessed by typing in ''yourservername/phpMyAdmin'' into the browser.
</p>