iksop 7 роки тому
батько
коміт
af7a1d8e4a

+ 5 - 5
app/config/bundles/hwi/oauth-bundle/parameters.yml.dist

@@ -1,6 +1,6 @@
 parameters:
-    client_id:           "1_4201udjx8vsw0go8g84wsksg4o8ogoow0sosc8k44c8cscwssw"
-    client_secret:       "42ymihqa8js408ggk4c0cccswcw8okcogww80co8cogsgc4woo"
-    access_token_url:    "http://127.0.0.1/base/app_dev.php/oauth/v2/token"
-    authorization_url:   "http://127.0.0.1/base/app_dev.php/oauth/v2/auth"
-    infos_url:           "http://127.0.0.1/base/app_dev.php/api/user/me"
+    client_id: '%env(OAUTH_CLIENT_ID)%'
+    client_secret: '%env(OAUTH_CLIENT_SECRET)%'
+    access_token_url: 'http://%env(HOST_BASE)%/oauth/v2/token'
+    authorization_url: 'http://%env(HOST_BASE)%/oauth/v2/auth'
+    infos_url: 'http://%env(HOST_BASE)%/api/user/me'

+ 6 - 6
app/config/bundles/ik/webservice-bundle/parameters.yml.dist

@@ -1,9 +1,9 @@
 parameters:
-    url_base: 'http://127.0.0.1/base/app_dev.php' # url app Base
-    url_mapas: 'http://127.0.0.1/mapas/app_dev.php' # url app Mapas
-    url_stats: 'http://127.0.0.1/stats/app_dev.php' # url app Stats
-    url_ftth: 'http://127.0.0.1/ftth/app_dev.php' # url app FTTH
-    url_radius: 'http://127.0.0.1/radius/app_dev.php' # url app Radius
+    url_base: 'http://%env(HOST_BASE)%' # url app Base
+    url_mapas: 'http://%env(HOST_MAPAS)%' # url app Mapas
+    url_stats: 'http://%env(HOST_STATS)%' # url app Stats
+    url_ftth: 'http://%env(HOST_FTTH)%' # url app FTTH
+    url_radius: 'http://%env(HOST_RADIUS)%' # url app Radius
 
     client: '%url_base%/api/clients.json'
 
@@ -18,4 +18,4 @@ parameters:
     remote_device_url: '%url_base%/api/devices.json'
     remote_device_log_url: '%url_base%/api/devicelogs.json'
     remote_get_map_url: '%url_mapas%/api/maps.json'
-    remote_get_object_type_url: '%url_mapas%/api/objecttypes.json'
+    remote_get_object_type_url: '%url_mapas%/api/objecttypes.json'

+ 1 - 1
app/config/parameters.yml.dist

@@ -35,7 +35,7 @@ parameters:
     env(AMQP_KEY) : ""
 
     cookie_domain_client: '%env(CLIENT)%'
-    cookie_domain: '%cookie_domain_client%.fd3.flowdat.com'
+    cookie_domain: '%cookie_domain_client%.flowdat.com'
     session_names: [flowdat_base_session, flowdat_ftth_session, flowdat_mapas_session, flowdat_stats_session, flowdat_radius_session, flowdat_cablemodem_session, flowdat_dhcp_session]
 
     nginx_name: nginx-proxy

+ 10 - 11
web/app_dev.php

@@ -1,25 +1,24 @@
 <?php
 
-use Symfony\Component\HttpFoundation\Request;
 use Symfony\Component\Debug\Debug;
+use Symfony\Component\HttpFoundation\Request;
 
 // If you don't want to setup permissions the proper way, just uncomment the following PHP line
-// read http://symfony.com/doc/current/setup.html#checking-symfony-application-configuration-and-setup
+// read https://symfony.com/doc/current/setup.html#checking-symfony-application-configuration-and-setup
 // for more information
 //umask(0000);
 
 // This check prevents access to debug front controllers that are deployed by accident to production servers.
 // Feel free to remove this, extend it, or make something more sophisticated.
-if (isset($_SERVER['HTTP_CLIENT_IP'])
-    || isset($_SERVER['HTTP_X_FORWARDED_FOR'])
-    || !(in_array(@$_SERVER['REMOTE_ADDR'], ['127.0.0.1', '::1']) || PHP_SAPI === 'cli-server')
-) {
-    // header('HTTP/1.0 403 Forbidden');
-    // exit('You are not allowed to access this file. Check '.basename(__FILE__).' for more information.');
-}
+//if (isset($_SERVER['HTTP_CLIENT_IP'])
+//    || isset($_SERVER['HTTP_X_FORWARDED_FOR'])
+//    || !(in_array(@$_SERVER['REMOTE_ADDR'], ['127.0.0.1', '::1'], true) || PHP_SAPI === 'cli-server')
+//) {
+//    header('HTTP/1.0 403 Forbidden');
+//    exit('You are not allowed to access this file. Check '.basename(__FILE__).' for more information.');
+//}
 
-/** @var \Composer\Autoload\ClassLoader $loader */
-$loader = require __DIR__.'/../vendor/autoload.php';
+require __DIR__.'/../vendor/autoload.php';
 Debug::enable();
 
 $kernel = new AppKernel('dev', true);