This tutorial will guide you through the installation of PHP Censor on FreeBSD Latest. PHP Censor is an open-source continuous integration server that can build and test your project source code on every code push or pull request.
Before starting, ensure that you have the following prerequisites:
To install PHP and its required extensions, use the following command:
$ pkg install php71 php71-mysqli php71-tokenizer php71-xml php71-mbstring php71-curl php71-gd
Next, install Composer by running:
$ pkg install composer
Create a new database for PHP Censor by running the following command:
$ mysql -u root -p
Enter password: <enter your MySQL/MariaDB password>
mysql> CREATE DATABASE php_censor;
mysql> GRANT ALL PRIVILEGES ON php_censor.* TO 'phpcensor'@'localhost' IDENTIFIED BY '<password>';
mysql> exit
Replace "
Download the latest version of PHP Censor from its GitHub repository using the following command:
$ cd /usr/local/www/
$ git clone https://github.com/php-censor/php-censor.git
Navigate to the PHP Censor directory and install its dependencies using Composer:
$ cd php-censor/
$ composer install
Rename the "config.dist.yml" file to "config.yml" and edit it to match your preferences:
$ cp config.dist.yml config.yml
$ nano config.yml
Update the database configuration by modifying the following:
database:
driver: mysqli
host: localhost
port: 3306
database: php_censor
username: phpcensor
password: <password>
Replace "
Create the directory structure that PHP Censor requires:
$ mkdir -p build/logs
$ mkdir -p build/artifacts
$ chmod -R 777 build
Start the PHP Censor server using the following command:
$ php bin/console start --env prod
You should see output similar to the following:
PHP Censor started successfully on http://0.0.0.0:8080
Open a web browser and navigate to the URL displayed in the previous step to access the PHP Censor dashboard. By default, the username and password are "admin".
Congratulations! You have now successfully installed PHP Censor on FreeBSD Latest, which is ready to build and test your project source code.
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!