aboutsummaryrefslogtreecommitdiffhomepage
path: root/app
diff options
context:
space:
mode:
authorJeremy Benoist <jeremy.benoist@gmail.com>2015-12-22 13:00:37 +0100
committerJeremy Benoist <jeremy.benoist@gmail.com>2016-01-15 09:35:38 +0100
commit5c895a7fd15822856fb407910264c5d95e1e223c (patch)
treea850ff9ccfd8067d4f8cdd341a2dda4324008afa /app
parent619cc45359ead519b64129181a07e14160fbbfcb (diff)
downloadwallabag-5c895a7fd15822856fb407910264c5d95e1e223c.tar.gz
wallabag-5c895a7fd15822856fb407910264c5d95e1e223c.tar.zst
wallabag-5c895a7fd15822856fb407910264c5d95e1e223c.zip
Update bundle & stock file
- update stock file (AppKernel, app.php, etc ..) from SymfonyStandard edition) - update bundle to latest release - remove security on profiler
Diffstat (limited to 'app')
-rw-r--r--app/AppCache.php2
-rw-r--r--app/AppKernel.php4
-rw-r--r--app/check.php6
-rw-r--r--app/config/config.yml5
-rw-r--r--app/config/routing.yml2
-rw-r--r--app/config/routing_dev.yml6
-rw-r--r--app/config/security.yml9
-rwxr-xr-xapp/console14
8 files changed, 24 insertions, 24 deletions
diff --git a/app/AppCache.php b/app/AppCache.php
index ddb51db0..639ec2cd 100644
--- a/app/AppCache.php
+++ b/app/AppCache.php
@@ -1,7 +1,5 @@
1<?php 1<?php
2 2
3require_once __DIR__.'/AppKernel.php';
4
5use Symfony\Bundle\FrameworkBundle\HttpCache\HttpCache; 3use Symfony\Bundle\FrameworkBundle\HttpCache\HttpCache;
6 4
7class AppCache extends HttpCache 5class AppCache extends HttpCache
diff --git a/app/AppKernel.php b/app/AppKernel.php
index d2aa8d1c..d97842f9 100644
--- a/app/AppKernel.php
+++ b/app/AppKernel.php
@@ -35,7 +35,7 @@ class AppKernel extends Kernel
35 new Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle(), 35 new Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle(),
36 ); 36 );
37 37
38 if (in_array($this->getEnvironment(), array('dev', 'test'))) { 38 if (in_array($this->getEnvironment(), array('dev', 'test'), true)) {
39 $bundles[] = new Symfony\Bundle\DebugBundle\DebugBundle(); 39 $bundles[] = new Symfony\Bundle\DebugBundle\DebugBundle();
40 $bundles[] = new Symfony\Bundle\WebProfilerBundle\WebProfilerBundle(); 40 $bundles[] = new Symfony\Bundle\WebProfilerBundle\WebProfilerBundle();
41 $bundles[] = new Sensio\Bundle\DistributionBundle\SensioDistributionBundle(); 41 $bundles[] = new Sensio\Bundle\DistributionBundle\SensioDistributionBundle();
@@ -48,6 +48,6 @@ class AppKernel extends Kernel
48 48
49 public function registerContainerConfiguration(LoaderInterface $loader) 49 public function registerContainerConfiguration(LoaderInterface $loader)
50 { 50 {
51 $loader->load(__DIR__.'/config/config_'.$this->getEnvironment().'.yml'); 51 $loader->load($this->getRootDir().'/config/config_'.$this->getEnvironment().'.yml');
52 } 52 }
53} 53}
diff --git a/app/check.php b/app/check.php
index 60ae0a8b..282507f7 100644
--- a/app/check.php
+++ b/app/check.php
@@ -80,7 +80,7 @@ function get_error_message(Requirement $requirement, $lineSize)
80 return; 80 return;
81 } 81 }
82 82
83 $errorMessage = wordwrap($requirement->getTestMessage(), $lineSize - 3, PHP_EOL.' ').PHP_EOL; 83 $errorMessage = wordwrap($requirement->getTestMessage(), $lineSize - 3, PHP_EOL.' ').PHP_EOL;
84 $errorMessage .= ' > '.wordwrap($requirement->getHelpText(), $lineSize - 5, PHP_EOL.' > ').PHP_EOL; 84 $errorMessage .= ' > '.wordwrap($requirement->getHelpText(), $lineSize - 5, PHP_EOL.' > ').PHP_EOL;
85 85
86 return $errorMessage; 86 return $errorMessage;
@@ -121,8 +121,8 @@ function echo_block($style, $title, $message)
121 echo PHP_EOL.PHP_EOL; 121 echo PHP_EOL.PHP_EOL;
122 122
123 echo_style($style, str_repeat(' ', $width).PHP_EOL); 123 echo_style($style, str_repeat(' ', $width).PHP_EOL);
124 echo_style($style, str_pad(' ['.$title.']', $width, ' ', STR_PAD_RIGHT).PHP_EOL); 124 echo_style($style, str_pad(' ['.$title.']', $width, ' ', STR_PAD_RIGHT).PHP_EOL);
125 echo_style($style, str_pad($message, $width, ' ', STR_PAD_RIGHT).PHP_EOL); 125 echo_style($style, str_pad($message, $width, ' ', STR_PAD_RIGHT).PHP_EOL);
126 echo_style($style, str_repeat(' ', $width).PHP_EOL); 126 echo_style($style, str_repeat(' ', $width).PHP_EOL);
127} 127}
128 128
diff --git a/app/config/config.yml b/app/config/config.yml
index 8e9369c2..5bc16dd9 100644
--- a/app/config/config.yml
+++ b/app/config/config.yml
@@ -59,9 +59,8 @@ twig:
59 warning_message: %warning_message% 59 warning_message: %warning_message%
60 paypal_url: "https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=9UBA65LG3FX9Y&lc=gb" 60 paypal_url: "https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=9UBA65LG3FX9Y&lc=gb"
61 flattr_url: "https://flattr.com/thing/1265480" 61 flattr_url: "https://flattr.com/thing/1265480"
62 form: 62 form_themes:
63 resources: 63 - "LexikFormFilterBundle:Form:form_div_layout.html.twig"
64 - LexikFormFilterBundle:Form:form_div_layout.html.twig
65 64
66# Assetic Configuration 65# Assetic Configuration
67assetic: 66assetic:
diff --git a/app/config/routing.yml b/app/config/routing.yml
index 1ca2f677..84b98d23 100644
--- a/app/config/routing.yml
+++ b/app/config/routing.yml
@@ -8,7 +8,7 @@ wallabag_api:
8 prefix: / 8 prefix: /
9 9
10app: 10app:
11 resource: @WallabagCoreBundle/Controller/ 11 resource: "@WallabagCoreBundle/Controller/"
12 type: annotation 12 type: annotation
13 13
14doc-api: 14doc-api:
diff --git a/app/config/routing_dev.yml b/app/config/routing_dev.yml
index 1a236e28..404f6a3b 100644
--- a/app/config/routing_dev.yml
+++ b/app/config/routing_dev.yml
@@ -6,13 +6,9 @@ _profiler:
6 resource: "@WebProfilerBundle/Resources/config/routing/profiler.xml" 6 resource: "@WebProfilerBundle/Resources/config/routing/profiler.xml"
7 prefix: /_profiler 7 prefix: /_profiler
8 8
9_configurator:
10 resource: "@SensioDistributionBundle/Resources/config/routing/webconfigurator.xml"
11 prefix: /_configurator
12
13_errors: 9_errors:
14 resource: "@TwigBundle/Resources/config/routing/errors.xml" 10 resource: "@TwigBundle/Resources/config/routing/errors.xml"
15 prefix: /_error 11 prefix: /_error
16 12
17_main: 13_main:
18 resource: routing.yml \ No newline at end of file 14 resource: routing.yml
diff --git a/app/config/security.yml b/app/config/security.yml
index 576cfd25..a99a7d80 100644
--- a/app/config/security.yml
+++ b/app/config/security.yml
@@ -15,6 +15,11 @@ security:
15 # the main part of the security, where you can set up firewalls 15 # the main part of the security, where you can set up firewalls
16 # for specific sections of your app 16 # for specific sections of your app
17 firewalls: 17 firewalls:
18 # disables authentication for assets and the profiler, adapt it according to your needs
19 dev:
20 pattern: ^/(_(profiler|wdt)|css|images|js)/
21 security: false
22
18 oauth_token: 23 oauth_token:
19 pattern: ^/oauth/v2/token 24 pattern: ^/oauth/v2/token
20 security: false 25 security: false
@@ -33,11 +38,11 @@ security:
33 pattern: ^/ 38 pattern: ^/
34 form_login: 39 form_login:
35 provider: fos_userbundle 40 provider: fos_userbundle
36 csrf_provider: security.csrf.token_manager 41 csrf_token_generator: security.csrf.token_manager
37 42
38 anonymous: true 43 anonymous: true
39 remember_me: 44 remember_me:
40 key: "%secret%" 45 secret: "%secret%"
41 lifetime: 31536000 46 lifetime: 31536000
42 path: / 47 path: /
43 domain: ~ 48 domain: ~
diff --git a/app/console b/app/console
index fa6a36e2..3b4c367c 100755
--- a/app/console
+++ b/app/console
@@ -1,18 +1,20 @@
1#!/usr/bin/env php 1#!/usr/bin/env php
2<?php 2<?php
3 3
4use Symfony\Bundle\FrameworkBundle\Console\Application;
5use Symfony\Component\Console\Input\ArgvInput;
6use Symfony\Component\Debug\Debug;
7
4// if you don't want to setup permissions the proper way, just uncomment the following PHP line 8// if you don't want to setup permissions the proper way, just uncomment the following PHP line
5// read http://symfony.com/doc/current/book/installation.html#configuration-and-setup for more information 9// read http://symfony.com/doc/current/book/installation.html#configuration-and-setup for more information
6//umask(0000); 10//umask(0000);
7 11
8set_time_limit(0); 12set_time_limit(0);
9 13
10require_once __DIR__.'/bootstrap.php.cache'; 14/**
11require_once __DIR__.'/AppKernel.php'; 15 * @var Composer\Autoload\ClassLoader $loader
12 16 */
13use Symfony\Bundle\FrameworkBundle\Console\Application; 17$loader = require __DIR__.'/autoload.php';
14use Symfony\Component\Console\Input\ArgvInput;
15use Symfony\Component\Debug\Debug;
16 18
17$input = new ArgvInput(); 19$input = new ArgvInput();
18$env = $input->getParameterOption(array('--env', '-e'), getenv('SYMFONY_ENV') ?: 'dev'); 20$env = $input->getParameterOption(array('--env', '-e'), getenv('SYMFONY_ENV') ?: 'dev');