1 <?php |
1 <?php |
2 |
2 |
3 $sesameBaseUrl = rtrim(env('CORPUSPAROLE_SESAME_BASE_URL'),'/').'/'; |
3 $sesameBaseUrl = rtrim(env('CORPUSPAROLE_SESAME_BASE_URL'),'/').'/'; |
|
4 $baseUrl = parse_url(env('APP_URL','http://localhost'), PHP_URL_PATH); |
|
5 $baseUrl = ($baseUrl && strlen($baseUrl)>0)?$baseUrl:"/"; |
4 |
6 |
5 return [ |
7 return [ |
6 'sesame_base_url' => $sesameBaseUrl, |
8 'sesame_base_url' => $sesameBaseUrl, |
7 'sesame_repository' => env('CORPUSPAROLE_SESAME_REPOSITORY'), |
9 'sesame_repository' => env('CORPUSPAROLE_SESAME_REPOSITORY'), |
8 'sesame_repository_raw' => env('CORPUSPAROLE_SESAME_REPOSITORY_RAW'), |
10 'sesame_repository_raw' => env('CORPUSPAROLE_SESAME_REPOSITORY_RAW'), |
79 ] |
81 ] |
80 ] |
82 ] |
81 ], |
83 ], |
82 |
84 |
83 'viaf_base_url' => 'http://viaf.org/viaf/', |
85 'viaf_base_url' => 'http://viaf.org/viaf/', |
84 'viaf_cache_expiration' => 60*24*30 |
86 'viaf_cache_expiration' => 60*24*30, |
|
87 |
|
88 'lexvo_base_url' => 'http://lexvo.org/id/iso639-3/', |
|
89 'lexvo_cache_expiration' => 60*24*30, |
|
90 'lexvo_sesame_query_url' => $sesameBaseUrl.'repositories/'.env('CORPUSPAROLE_SESAME_LEXVO_REPOSITORY'), |
|
91 |
|
92 'bo_client_environment' => [ |
|
93 "modulePrefix" => "bo-client", |
|
94 "podModulePrefix" => "bo-client/pods", |
|
95 "environment" => "production", |
|
96 "baseURL" => $baseUrl, |
|
97 "locationType" => "hash", |
|
98 "i18n" => ["defaultLocale" => "fr"], |
|
99 "EmberENV" => ["FEATURES"=>(object)[]], # to force json serialisation as object |
|
100 "APP" => [ |
|
101 "bo-doc-viaf-autocomplete" => [ |
|
102 "viafQueryUrl" => "http://viaf.org/viaf/AutoSuggest?query=", |
|
103 "viafBaseUrl" => "http://viaf.org/viaf/" |
|
104 ], |
|
105 "LOG_RESOLVER" => true, |
|
106 "LOG_ACTIVE_GENERATION" => true, |
|
107 "LOG_TRANSITIONS" => true, |
|
108 "LOG_TRANSITIONS_INTERNAL" => true, |
|
109 "LOG_VIEW_LOOKUPS" => true, |
|
110 "name" => "bo-client", |
|
111 "version" => "0.0.0 " |
|
112 ], |
|
113 "contentSecurityPolicy" => [ |
|
114 "default-src" => "'none'", |
|
115 "script-src" => "'self'", |
|
116 "font-src" => "'self'", |
|
117 "connect-src" => "'self' *", |
|
118 "img-src" => "'self'", |
|
119 "style-src" => "'self' *", |
|
120 "media-src" => "'self'" |
|
121 ], |
|
122 "contentSecurityPolicyHeader" => "Content-Security-Policy-Report-Only", |
|
123 "exportApplicationGlobal" => true |
|
124 ] |
85 ]; |
125 ]; |