Deleted daemon mode (You should use worker mode instead)
This commit is contained in:
parent
5e0dadf5e1
commit
d77f0e8474
12 changed files with 23 additions and 392 deletions
|
|
@ -7,7 +7,6 @@ Getting Started
|
|||
* [Installing PHP Censor](installing.md)
|
||||
* [Adding a Virtual Host](virtual_host.md)
|
||||
* [Run builds using a worker](workers/worker.md)
|
||||
* [Run builds using a daemon](workers/daemon.md)
|
||||
* [Run builds using cronjob](workers/cron.md)
|
||||
* [Adding PHP Censor Support to Your Projects](config.md)
|
||||
* [Setting up Logging](logging.md)
|
||||
|
|
|
|||
|
|
@ -20,5 +20,6 @@ Installing PHP Censor Manually
|
|||
* Go to the PHP Censor directory: `cd /var/www/php-censor`
|
||||
* Install dependencies using Composer: `composer install`
|
||||
* Install PHP Censor itself: `./bin/console php-censor:install`
|
||||
* [Add a virtual host to your web server](virtual_host.md), pointing to the `public` directory within your new PHP Censor directory. You'll need to set up rewrite rules to point all non-existent requests to PHP Censor.
|
||||
* [Set up the PHP Censor Worker](workers/worker.md), or you can run builds using the [daemon](workers/daemon.md) or [a cron-job](workers/cron.md) to run PHP Censor builds.
|
||||
* [Add a virtual host to your web server](virtual_host.md), pointing to the `public` directory within your new PHP
|
||||
Censor directory. You'll need to set up rewrite rules to point all non-existent requests to PHP Censor.
|
||||
* [Set up the PHP Censor Worker](workers/worker.md), or [a cron-job](workers/cron.md) to run PHP Censor builds.
|
||||
|
|
|
|||
|
|
@ -1,9 +1,8 @@
|
|||
Run builds using cronjob
|
||||
========================
|
||||
|
||||
Running builds using cron is a quick and simple method of getting up and running with PHP Censor. It also removes the need for PHP Censor to be running all the time.
|
||||
|
||||
If you want a little more control over how PHP Censor runs, you may want to [set up the daemon](workers/daemon.md) instead.
|
||||
Running builds using cron is a quick and simple method of getting up and running with PHP Censor. It also removes the
|
||||
need for PHP Censor to be running all the time.
|
||||
|
||||
Setting up the Cron Job
|
||||
-----------------------
|
||||
|
|
|
|||
|
|
@ -1,23 +0,0 @@
|
|||
Run builds using a daemon
|
||||
=========================
|
||||
|
||||
The PHP Censor daemon runs in the background on your server and continuously checks for new builds. Unless already running a build, the daemon should pick up and start running new builds within seconds of being created.
|
||||
|
||||
The daemon is also useful if you want to run multiple PHP Censor workers in a virtualised environment (i.e. Docker)
|
||||
|
||||
If you want to run PHP Censor builds on a regular schedule instead, you should [set up a cronjob](workers/cron.md).
|
||||
|
||||
Starting the Daemon
|
||||
-------------------
|
||||
|
||||
On a Linux/Unix server, the following command will start the daemon and keep it running even when you log out of the server:
|
||||
|
||||
```sh
|
||||
nohup php ./daemonise php-censor:daemonise >/dev/null 2>&1 &
|
||||
```
|
||||
|
||||
If you need to debug what's going on with your builds, you can also run the daemon directly using the following command, which will output the daemon's log directly to your terminal:
|
||||
|
||||
```sh
|
||||
php daemonise php-censor:daemonise
|
||||
```
|
||||
|
|
@ -1,16 +1,21 @@
|
|||
Run builds using a worker
|
||||
=========================
|
||||
|
||||
The PHP Censor Worker runs in the background on your server and waits for new builds to be added to a Beanstalkd queue. Unless already running a build, the worker will pick up and start running new builds almost immediately after their creation.
|
||||
The PHP Censor Worker runs in the background on your server and waits for new builds to be added to a Beanstalkd queue.
|
||||
Unless already running a build, the worker will pick up and start running new builds almost immediately after their
|
||||
creation.
|
||||
|
||||
The worker is the recommended way to run PHP Censor builds. You can run several workers all watching one queue, allowing jobs to be run simultaneously without the overhead of polling your MySQL database.
|
||||
The worker is the recommended way to run PHP Censor builds. You can run several workers all watching one queue,
|
||||
allowing jobs to be run simultaneously without the overhead of polling your MySQL database.
|
||||
|
||||
If you can't run Beanstalkd on your server, or would prefer to run builds on a regular schedule, you should consider using the [build daemon](workers/daemon.md) or [running builds via Cron](workers/cron.md).
|
||||
If you can't run Beanstalkd on your server, or would prefer to run builds on a regular schedule, you should consider
|
||||
using the [running builds via Cron](workers/cron.md).
|
||||
|
||||
Pre-Requisites
|
||||
--------------
|
||||
|
||||
* You need to install [Beanstalkd](http://kr.github.io/beanstalkd/) - On Ubuntu, this is as simple as running `apt-get install beanstalkd`.
|
||||
* You need to install [Beanstalkd](http://kr.github.io/beanstalkd/) - On Ubuntu, this is as simple as running
|
||||
`apt-get install beanstalkd`.
|
||||
* [Supervisord](http://supervisord.org/) needs to be installed and running on your server.
|
||||
|
||||
Setting up the PHP Censor worker
|
||||
|
|
@ -20,14 +25,10 @@ Setting up the PHP Censor worker
|
|||
|
||||
Setting up the worker on a new installation of PHP Censor is as simple as entering the appropriate values for your Beanstalkd server hostname and queue name when running the PHP Censor installer. By default, the installer assumes that you'll be using beanstalkd on `localhost` and will use the queue name `php-censor-queue`.
|
||||
|
||||

|
||||
|
||||
### On an existing installation
|
||||
|
||||
On an existing installation, to set up the worker, you simply need to add the beanstalkd host and queue names directly into your `config.yml` file. You should add a `worker` key beneath the `php-censor` section, with the properties `host` and `queue` as outlined in the screenshot below:
|
||||
|
||||

|
||||
|
||||
Running the PHP Censor worker
|
||||
-----------------------------
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue