This tutorial will guide you through the steps to install PHP-Proxy on Arch Linux. PHP-Proxy is a free, open-source web proxy written in PHP that allows you to surf anonymously and bypass filters and firewalls.
First, update your package manager:
$ sudo pacman -Syu
Then, install Apache, PHP, MySQL and PHP extensions required by PHP-Proxy:
$ sudo pacman -S apache php php-fpm php-mysql php-gd php-curl mariadb
Enable the Apache service:
$ sudo systemctl enable httpd.service
Start the Apache service:
$ sudo systemctl start httpd.service
Open up Apache configuration file /etc/httpd/conf/httpd.conf
using your favorite text editor and edit the following lines:
# LoadModule authn_file_module modules/mod_authn_file.so
# LoadModule authn_dbm_module modules/mod_authn_dbm.so
# LoadModule authn_anon_module modules/mod_authn_anon.so
# LoadModule authn_dbd_module modules/mod_authn_dbd.so
# LoadModule authn_socache_module modules/mod_authn_socache.so
# LoadModule authz_host_module modules/mod_authz_host.so
# LoadModule authz_groupfile_module modules/mod_authz_groupfile.so
# LoadModule authz_user_module modules/mod_authz_user.so
# LoadModule authz_dbm_module modules/mod_authz_dbm.so
# LoadModule authz_owner_module modules/mod_authz_owner.so
# LoadModule authz_dbd_module modules/mod_authz_dbd.so
# LoadModule authz_socache_module modules/mod_authz_socache.so
LoadModule authz_core_module modules/mod_authz_core.so
# LoadModule access_compat_module modules/mod_access_compat.so
# LoadModule auth_basic_module modules/mod_auth_basic.so
Uncomment these lines and save the file.
Next, add the following lines to the end of the file:
<Directory /usr/share/webapps/php-proxy>
Options FollowSymLinks MultiViews
AllowOverride All
Require all granted
</Directory>
Save and exit the file.
Download the latest version of PHP-Proxy from the official website using wget
command:
$ wget https://github.com/Athlon1600/php-proxy-app/archive/master.zip
Extract the downloaded zip file and move it to the Apache document root directory:
$ unzip master.zip
$ sudo mv php-proxy-app-master /srv/http/php-proxy
Give Apache permission to access the PHP-Proxy files:
$ sudo chown -R http:http /srv/http/php-proxy
Create a new MySQL database for PHP-Proxy:
$ mysql -u root -p
Enter password:
MariaDB [(none)]> CREATE DATABASE `php_proxy` CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci;
MariaDB [(none)]> GRANT ALL PRIVILEGES ON `php_proxy`.* TO `php_user`@localhost IDENTIFIED BY 'php_user_password';
MariaDB [(none)]> FLUSH PRIVILEGES;
MariaDB [(none)]> exit
Copy the config.inc.php.dist
file to config.inc.php
:
$ cd /srv/http/php-proxy/includes
$ cp config.inc.php.dist config.inc.php
Open the config.inc.php
file and edit the following lines:
define('PROXY_URL', 'http://localhost/php-proxy/index.php?url=');
define('DB_HOST', 'localhost');
define('DB_NAME', 'php_proxy');
define('DB_USER', 'php_user');
define('DB_PASS', 'php_user_password');
Save and exiting the file.
Restart the Apache service:
$ sudo systemctl restart httpd.service
Open up your web browser and access the PHP-Proxy installation page using the URL:
http://localhost/php-proxy/install.php
Follow the on-screen instructions to install and configure PHP-Proxy.
Once the installation is done, you can access PHP-Proxy by opening the URL:
http://localhost/php-proxy
Congratulations! You have successfully installed PHP-Proxy on Arch Linux.
If you want to self-host in an easy, hands free way, need an external IP address, or simply want your data in your own hands, give IPv6.rs a try!
Alternatively, for the best virtual desktop, try Shells!