Browse Source

Merge pull request #2109 from knewmanTE/silex-orm-fix

Silex orm fix
Nate 9 years ago
parent
commit
f6ef6da72b
2 changed files with 3 additions and 4 deletions
  1. 1 1
      frameworks/PHP/silex-orm/setup.sh
  2. 2 3
      frameworks/PHP/silex-orm/web/index.php

+ 1 - 1
frameworks/PHP/silex-orm/setup.sh

@@ -2,7 +2,7 @@
 
 fw_depends php nginx composer
 
-sed -i 's|192.168.100.102|'"${DBHOST}"'|g' web/index.php
+sed -i 's|127.0.0.1|'"${DBHOST}"'|g' web/index.php
 sed -i 's|".*/FrameworkBenchmarks/php-silex-orm|"'"${TROOT}"'|g' deploy/php-silex-orm
 sed -i 's|Directory .*/FrameworkBenchmarks/php-silex-orm|Directory '"${TROOT}"'|g' deploy/php-silex-orm
 sed -i 's|root .*/FrameworkBenchmarks/php-silex-orm|root '"${TROOT}"'|g' deploy/nginx.conf

+ 2 - 3
frameworks/PHP/silex-orm/web/index.php

@@ -14,7 +14,7 @@ $loader = require_once __DIR__.'/../vendor/autoload.php';
 
 $app = new Silex\Application();
 
-$dbh = new PDO('mysql:host=192.168.100.102;dbname=hello_world', 'benchmarkdbuser', 'benchmarkdbpass', array(
+$dbh = new PDO('mysql:host=127.0.0.1;dbname=hello_world', 'benchmarkdbuser', 'benchmarkdbpass', array(
     PDO::ATTR_PERSISTENT => true
 ));
 
@@ -34,8 +34,7 @@ $app->register(new DoctrineOrmServiceProvider, array(
                 'path' => __DIR__.'/../src/Entity',
                 'use_simple_annotation_reader' => false,
             ),
-        ),
-        'metadata_cache' => 'redis'
+        )
     ),
 ));