Configuration

This commit is contained in:
Michael RICOIS 2013-06-18 06:58:53 +00:00
parent b4366f5599
commit 622a80ff24
5 changed files with 66 additions and 122 deletions

View File

@ -1,12 +1,11 @@
<?php
define('INCLUDE_PATH', realpath(dirname(__FILE__)).'/');
/** BATCH **/
define('FILLER',' ');
define('VERSION_FICHIER_BODACC','0106');
define('LONGUEUR_LIGNE_SORTIE', 2000);
/** Paramétres du FTP des JO **/
define('BODACC_FTP_URL', 'ftp.journal-officiel.gouv.fr');
define('BODACC_FTP_USER', 'SCORE');
@ -19,7 +18,7 @@ define('HUGIN_FTP_URL', 'ftp.companynews.fr');
define('HUGIN_FTP_USER', 'scores');
define('HUGIN_FTP_PASS', 'scores_632');
define('HUGIN_LOCAL_DIR', '/home/data/sources/infosreg/hugin/');
/** Paramétres du FTP de ActusNews : Communiqués de presse **/
define('ACTUSNEWS_FTP_URL', 'ftp.actusnews.com');
define('ACTUSNEWS_FTP_USER', 'scores_act');
@ -31,24 +30,24 @@ define('DIRELEASE_FTP_URL', 'ftp.actusnews.com');
define('DIRELEASE_FTP_USER', 'scores_dir');
define('DIRELEASE_FTP_PASS', '-gT52sQ');
define('DIRELEASE_LOCAL_DIR', '/home/data/sources/infosreg/direlease/');
/** Paramétres du FTP des Echos: Communiqués de presse **/
define('LESECHOS_FTP_URL', 'ftp.webdisclosure.com');
define('LESECHOS_FTP_USER', 'Scores');
define('LESECHOS_FTP_PASS', 'scores2001');
define('LESECHOS_LOCAL_DIR', '/home/data/sources/infosreg/lesechos/');
/** Paramétres du FTP de BusinessWire : Communiqués de presse **/
define('BUSINESSWIRE_LOCAL_DIR_INCOMING', '/home/data/ftp/businesswire/');
define('BUSINESSWIRE_LOCAL_DIR', '/home/data/infosreg/businesswire/');
/** Base de données de S&D **/
define ('MYSQL_HOST', '192.168.3.30');
define ('MYSQL_USER', 'wsuser');
define ('MYSQL_PASS', 'wspass2012');
define ('MYSQL_DEFAULT_DB', 'jo');
define ('MYSQL_SQL_LOG', 'NONE');
define ('SPHINX_HOST', '192.168.3.32');
define ('SPHINX_PORT', 9312);
@ -57,20 +56,20 @@ define ('SPHINX_ENT_PORT', 9312);
define ('SPHINX_DIR_HOST', '192.168.3.32');
define ('SPHINX_DIR_PORT', 9312);
define ('SPHINX_ACT_HOST', '192.168.3.25');
define ('SPHINX_ACT_PORT', 3312);
define ('SPHINX_HISTO_HOST', '192.168.3.25');
define ('SPHINX_HISTO_PORT', 3312);
/** SERVEUR DE MESSAGERIE **/
define ('SMTP_HOST', 'smtp.celeste.fr');
define ('SMTP_PORT', 25);
define ('SMTP_USER', '');
define ('SMTP_PASS', '');
/** INFOGREFFE **/
define('INFOGREFFE_DISPO', true);
define('INFOGREFFE_DISPO_WS', true);
@ -79,7 +78,7 @@ define('INFOGREFFE_WS_URL', 'https://webservices.infogreffe.fr/WSContextInfogref
define('INFOGREFFE_WS_URI', 'https://webservices.infogreffe.fr/');
define('INFOGREFFE_WS_USER', '85000109');
define('INFOGREFFE_WS_PASS', '166');
/** AMABIS **/
define('AMABIS_WS_URL', 'http://sw4.amabis.com:5101');
define('AMABIS_WS_URI', 'http://sw4.amabis.com:5101');

View File

@ -1,11 +1,11 @@
<?php
define('INCLUDE_PATH', realpath(dirname(__FILE__)).'/');
/** BATCH **/
define('FILLER',' ');
define('VERSION_FICHIER_BODACC','0106');
define('LONGUEUR_LIGNE_SORTIE', 2000);
/** Paramétres du FTP des JO **/
define('BODACC_FTP_URL', 'ftp.journal-officiel.gouv.fr');
define('BODACC_FTP_USER', 'SCORE');
@ -18,7 +18,7 @@ define('HUGIN_FTP_URL', 'ftp.companynews.fr');
define('HUGIN_FTP_USER', 'scores');
define('HUGIN_FTP_PASS', 'scores_632');
define('HUGIN_LOCAL_DIR', '/home/data/infosreg/hugin/');
/** Paramétres du FTP de ActusNews : Communiqués de presse **/
define('ACTUSNEWS_FTP_URL', 'ftp.actusnews.com');
define('ACTUSNEWS_FTP_USER', 'scores_act');
@ -30,24 +30,24 @@ define('DIRELEASE_FTP_URL', 'ftp.actusnews.com');
define('DIRELEASE_FTP_USER', 'scores_dir');
define('DIRELEASE_FTP_PASS', '-gT52sQ');
define('DIRELEASE_LOCAL_DIR', '/home/data/infosreg/direlease/');
/** Paramétres du FTP des Echos: Communiqués de presse **/
define('LESECHOS_FTP_URL', 'ftp.webdisclosure.com');
define('LESECHOS_FTP_USER', 'Scores');
define('LESECHOS_FTP_PASS', 'scores2001');
define('LESECHOS_LOCAL_DIR', '/home/data/infosreg/lesechos/');
/** Paramétres du FTP de BusinessWire : Communiqués de presse **/
define('BUSINESSWIRE_LOCAL_DIR_INCOMING', '/home/data/ftp/businesswire/');
define('BUSINESSWIRE_LOCAL_DIR', '/home/data/infosreg/businesswire/');
/** Base de données de S&D **/
define ('MYSQL_HOST', '192.168.3.30');
define ('MYSQL_USER', 'root');
define ('MYSQL_PASS', 'scores');
define ('MYSQL_DEFAULT_DB', 'jo');
define ('MYSQL_SQL_LOG', 'NONE');
define ('SPHINX_HOST', '192.168.3.32');
define ('SPHINX_PORT', 9312);
@ -56,22 +56,22 @@ define ('SPHINX_PORT', 9312);
define ('SPHINX_ENT_HOST', '192.168.3.32');
define ('SPHINX_ENT_PORT', 9312);
define ('SPHINX_DIR_HOST', '192.168.3.32');
define ('SPHINX_DIR_PORT', 9312);
define ('SPHINX_ACT_HOST', '192.168.3.32');
define ('SPHINX_ACT_PORT', 9312);
define ('SPHINX_HISTO_HOST', '192.168.3.32');
define ('SPHINX_HISTO_PORT', 9312);
/** SERVEUR DE MESSAGERIE **/
define ('SMTP_HOST', 'smtp.free.fr');
define ('SMTP_PORT', 25);
define ('SMTP_USER', '');
define ('SMTP_PASS', '');
/** INFOGREFFE **/
define('INFOGREFFE_DISPO', true);
define('INFOGREFFE_DISPO_WS', true);
@ -80,7 +80,7 @@ define('INFOGREFFE_WS_URL', 'https://webservices.infogreffe.fr/WSContextInfogref
define('INFOGREFFE_WS_URI', 'https://webservices.infogreffe.fr/');
define('INFOGREFFE_WS_USER', '85000109');
define('INFOGREFFE_WS_PASS', '166');
/** AMABIS **/
define('AMABIS_WS_URL', 'http://sw4.amabis.com:5101');
define('AMABIS_WS_URI', 'http://sw4.amabis.com:5101');
@ -90,4 +90,17 @@ define ('DOC_WEB_LOCAL', realpath('d:/www/dataws/'));
define ('DOC_WEB_URL', '/data/');
/** LOGGING **/
define('LOG_PATH', realpath('d:/www/dataws/log/'));
define('LOG_PATH', realpath('d:/www/dataws/log/'));
define ('DATETIME', date('YmdHis'));
define ('DATE', substr(DATETIME,0,8));
define ('TIME', substr(DATETIME,8,6));
define ('DATE_LISIBLE', substr(DATETIME,6,2).'/'.substr(DATETIME,4,2).'/'.substr(DATETIME,0,4));
define ('TIME_LISIBLE', substr(DATETIME,8,2).':'.substr(DATETIME,10,2).':'.substr(DATETIME,12,2));
/**
* Inclusion du Framework
*/
if( !defined('FWK_PATH') )
include_once realpath(dirname(__FILE__).'/../framework/fwk.php');

View File

@ -1,11 +1,11 @@
<?php
define('INCLUDE_PATH', realpath(dirname(__FILE__)).'/');
/** BATCH **/
define('FILLER',' ');
define('VERSION_FICHIER_BODACC','0106');
define('LONGUEUR_LIGNE_SORTIE', 2000);
/** Paramétres du FTP des JO **/
define('BODACC_FTP_URL', 'ftp.journal-officiel.gouv.fr');
define('BODACC_FTP_USER', 'SCORE');
@ -18,7 +18,7 @@ define('HUGIN_FTP_URL', 'ftp.companynews.fr');
define('HUGIN_FTP_USER', 'scores');
define('HUGIN_FTP_PASS', 'scores_632');
define('HUGIN_LOCAL_DIR', '/home/data/infosreg/hugin/');
/** Paramétres du FTP de ActusNews : Communiqués de presse **/
define('ACTUSNEWS_FTP_URL', 'ftp.actusnews.com');
define('ACTUSNEWS_FTP_USER', 'scores_act');
@ -30,24 +30,24 @@ define('DIRELEASE_FTP_URL', 'ftp.actusnews.com');
define('DIRELEASE_FTP_USER', 'scores_dir');
define('DIRELEASE_FTP_PASS', '-gT52sQ');
define('DIRELEASE_LOCAL_DIR', '/home/data/infosreg/direlease/');
/** Paramétres du FTP des Echos: Communiqués de presse **/
define('LESECHOS_FTP_URL', 'ftp.webdisclosure.com');
define('LESECHOS_FTP_USER', 'Scores');
define('LESECHOS_FTP_PASS', 'scores2001');
define('LESECHOS_LOCAL_DIR', '/home/data/infosreg/lesechos/');
/** Paramétres du FTP de BusinessWire : Communiqués de presse **/
define('BUSINESSWIRE_LOCAL_DIR_INCOMING', '/home/data/ftp/businesswire/');
define('BUSINESSWIRE_LOCAL_DIR', '/home/data/infosreg/businesswire/');
/** Base de données de S&D **/
define ('MYSQL_HOST', '192.168.78.230');
define ('MYSQL_USER', 'wsuser');
define ('MYSQL_PASS', 'scores');
define ('MYSQL_DEFAULT_DB', 'jo');
define ('MYSQL_SQL_LOG', 'NONE');
define ('SPHINX_HOST', '192.168.3.32');
define ('SPHINX_PORT', 9312);
@ -56,20 +56,20 @@ define ('SPHINX_ENT_PORT', 9312);
define ('SPHINX_DIR_HOST', '192.168.3.32');
define ('SPHINX_DIR_PORT', 9312);
define ('SPHINX_ACT_HOST', '192.168.3.32');
define ('SPHINX_ACT_PORT', 9312);
define ('SPHINX_HISTO_HOST', '192.168.3.32');
define ('SPHINX_HISTO_PORT', 9312);
/** SERVEUR DE MESSAGERIE **/
define ('SMTP_HOST', 'smtp.free.fr');
define ('SMTP_PORT', 25);
define ('SMTP_USER', '');
define ('SMTP_PASS', '');
/** INFOGREFFE **/
define('INFOGREFFE_DISPO', true);
define('INFOGREFFE_DISPO_WS', true);
@ -78,7 +78,7 @@ define('INFOGREFFE_WS_URL', 'https://webservices.infogreffe.fr/WSContextInfogref
define('INFOGREFFE_WS_URI', 'https://webservices.infogreffe.fr/');
define('INFOGREFFE_WS_USER', '85000109');
define('INFOGREFFE_WS_PASS', '166');
/** AMABIS **/
define('AMABIS_WS_URL', 'http://sw4.amabis.com:5101');
define('AMABIS_WS_URI', 'http://sw4.amabis.com:5101');
@ -88,4 +88,17 @@ define ('DOC_WEB_LOCAL', '/sites/dataws/');
define ('DOC_WEB_URL', '/data/');
/** LOGGING **/
define('LOG_PATH', '/sites/dataws/log');
define('LOG_PATH', '/sites/dataws/log');
define ('DATETIME', date('YmdHis'));
define ('DATE', substr(DATETIME,0,8));
define ('TIME', substr(DATETIME,8,6));
define ('DATE_LISIBLE', substr(DATETIME,6,2).'/'.substr(DATETIME,4,2).'/'.substr(DATETIME,0,4));
define ('TIME_LISIBLE', substr(DATETIME,8,2).':'.substr(DATETIME,10,2).':'.substr(DATETIME,12,2));
/**
* Inclusion du Framework
*/
if( !defined('FWK_PATH') )
include_once realpath(dirname(__FILE__).'/../framework/fwk.php');

View File

@ -1,3 +0,0 @@
<?
?>

View File

@ -1,78 +0,0 @@
<?
define ('DATETIME', date('YmdHis'));
define ('DATE', substr(DATETIME,0,8));
define ('TIME', substr(DATETIME,8,6));
define ('DATE_LISIBLE', substr(DATETIME,6,2).'/'.substr(DATETIME,4,2).'/'.substr(DATETIME,0,4));
define ('TIME_LISIBLE', substr(DATETIME,8,2).':'.substr(DATETIME,10,2).':'.substr(DATETIME,12,2));
/**
* Inclusion du fichier de configuration des includes Métiers de S&D
*/
include_once realpath(dirname(__FILE__).'/config.php');
/**
* Inclusion du Framework
*/
if( !defined('FWK_PATH') )
include_once realpath(dirname(__FILE__).'/../framework/fwk.php');
/** Instance de la connexion à la base de données
* Cette instance est utilisée par tous les scripts pour accéder à la base de données
*//*
class DB extends DB_sql
{
function DB() {
$this->Host = MYSQL_HOST;
$this->Database = MYSQL_DEFAULT_DB;
$this->User = MYSQL_USER;
$this->Password = MYSQL_PASS;
}
function getRow() {
$ret= $this->Record;
for( $i= 0; $i<count($this->Record); $i++ ) { if( !isset($ret[$i]) ) break; unset($ret[$i]); }
return $ret;
}
function query($q) {
if ( MYSQL_SQL_LOG != 'NONE' ) $time_start=getmicrotime();
$ret=DB_sql::query($q);
if ( MYSQL_SQL_LOG == 'NONE' ) return $ret;
$time_end= getmicrotime();
$time_total= $time_end-$time_start;
$time_total= substr((string)$time_total,0,10);
$now= date('Y/m/d H:i:s', $time_start);
if ($ret<1)
$mysqlerror = mysql_errno() .' : '. mysql_error();
else
$mysqlerror = '';
$sqlAction=strtoupper(substr(trim($q),0,6));
if ( MYSQL_SQL_LOG=='SELECT' && $sqlAction=='SELECT' )
$logOption='_select';
elseif ( MYSQL_SQL_LOG=='UPDATE' && ( $sqlAction=='UPDATE' || $sqlAction=='INSERT' || $sqlAction=='DELETE' ) )
$logOption='_update';
else
$logOption='';
$fh=@fopen(REP_TEMP . 'db_mysql'.$logOption.'.log', 'a+');
if ($fh) {
@fwrite($fh, "$now\t$time_total\t" . MYSQL_HOST ."\t". MYSQL_USER ."\t". MYSQL_DB ."\t$mysqlerror\t$q\r\n");
@fclose($fh);
}
$mySqlErrTab=explode(' : ', $mysqlerror);
$mySqlErrno=(int)$mySqlErrTab[0];
if ( $mySqlErrno > 0 && $mySqlErrno !=1062 ) {
mail( 'Erreur MySQL '.$mySqlErrno, $mysqlerror ."\n\n". $q );
}
return $ret;
}
}*/
?>