Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fixed previous merge

  • Loading branch information...
commit 696d9895c21413405a268ce19714a222e6c3b5e4 1 parent 268f04c
Grégoire Pineau lyrixx authored
Showing with 10 additions and 1 deletion.
  1. +5 −0 README.rst
  2. +2 −1  compile
  3. +3 −0  src/controllers.php
5 README.rst
View
@@ -191,6 +191,11 @@ You need to set an environment variable in your Apache configuration::
SetEnv SISMO_BUILD_TOKEN "YOUR_TOKEN"
+You can also set an environment variable in your config file
+(``~/.sismo/config.php``)::
+
+ putenv('SISMO_BUILD_TOKEN=YOUR_TOKEN');
+
Replace YOUR_TOKEN with something more secure, as anyone with this token
could use it to trigger builds. Then set your post-receive URL appropriately.
For example::
3  compile
View
@@ -77,8 +77,9 @@ $classes = array (
'Symfony\Component\HttpKernel\Event\KernelEvent',
'Symfony\Component\HttpKernel\Event\PostResponseEvent',
'Symfony\Component\HttpKernel\Exception\HttpException',
- 'Symfony\Component\HttpKernel\Exception\NotFoundHttpException',
+ 'Symfony\Component\HttpKernel\Exception\AccessDeniedHttpException',
'Symfony\Component\HttpKernel\Exception\MethodNotAllowedHttpException',
+ 'Symfony\Component\HttpKernel\Exception\NotFoundHttpException',
'Symfony\Component\HttpKernel\HttpKernel',
'Symfony\Component\HttpKernel\KernelEvents',
'Symfony\Component\Process\ProcessBuilder',
3  src/controllers.php
View
@@ -57,6 +57,9 @@
})->bind('commit');
$app->post('/{slug}/build/{token}', function($slug, $token) use ($app) {
+ // Boot sismo
+ $app['sismo'];
+
if (!$server_token = getenv('SISMO_BUILD_TOKEN')) {
throw new NotFoundHttpException('Not found.');
}
Please sign in to comment.
Something went wrong with that request. Please try again.