Docs/工作-华金/配置指南.html
2022-10-18 16:59:37 +08:00

1063 lines
No EOL
39 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="tool" content="leanote-desktop-app">
<title>配置指南</title>
<style>
.tab{font-size:12px; margin-bottom: 10px;}
.tab a{cursor:pointer;cursor:pointer;display:inline-block;margin-right:10px;color:#000}#tab-html{color:#ccc}
.content-container .content-html{visibility: hidden;}
.content-container.html .content-markdown{display:none}
.content-container.html .content-html{display:block; visibility: visible;}
.content-container.html #tab-markdown{color:#ccc}
.content-container.html #tab-html{color:#000}
.content-markdown {overflow: auto;}
textarea {display: none;}
*{font-family:"lucida grande","lucida sans unicode",lucida,helvetica,"Hiragino Sans GB","Microsoft YaHei","WenQuanYi Micro Hei",sans-serif;}
body {
margin: 0;
}
/*公用文字样式*/
h1{font-size:30px}h2{font-size:24px}h3{font-size:18px}h4{font-size:14px}
.note-container{
width:850px;
margin:auto;
padding: 10px 20px;
box-shadow: 1px 1px 10px #eee;
}
#title {
margin: 0;
}
table {
margin-bottom: 16px;
border-collapse: collapse;
}
table th, table td {
padding: 6px 13px;
border: 1px solid #ddd;
}
table th {
font-weight: bold;
}
table tr {
background-color: none;
border-top: 1px solid #ccc;
}
table tr:nth-child(2n) {
background-color: rgb(247, 247, 249);
}
.mce-item-table, .mce-item-table td, .mce-item-table th, .mce-item-table caption {
border: 1px solid #ddd;
border-collapse: collapse;
padding: 6px 13px;
}
blockquote {
border-left-width:10px;
background-color:rgba(128,128,128,0.05);
border-top-right-radius:5px;
border-bottom-right-radius:5px;
padding:15px 20px;
border-left:5px solid rgba(128,128,128,0.075);
}
blockquote p {
margin-bottom:1.1em;
font-size:1em;
line-height:1.45
}
blockquote ul:last-child,blockquote ol:last-child {
margin-bottom:0
}
pre {
padding: 18px;
background-color: #f7f7f9;
border: 1px solid #e1e1e8;
border-radius: 3px;
display: block;
}
code {
padding: 2px 4px;
font-size: 90%;
color: #c7254e;
white-space: nowrap;
background-color: #f9f2f4;
border-radius: 4px;
}
.footnote {
vertical-align: top;
position: relative;
top: -0.5em;
font-size: .8em;
}
hr {
margin:2em 0
}
img {
max-width:100%;
display: block;
margin: auto;
}
pre {
word-break:break-word
}
p,pre,pre.prettyprint,blockquote {
margin:0 0 1.1em
}
hr {
margin:2em 0
}
img {
max-width:100%
}
.sequence-diagram,.flow-chart {
text-align:center;
margin-bottom:1.1em
}
.sequence-diagram text,.flow-chart text {
font-size:15px !important;
font-family:"Source Sans Pro",sans-serif !important
}
.sequence-diagram [fill="#ffffff"],.flow-chart [fill="#ffffff"] {
fill:#f6f6f6
}
.sequence-diagram [stroke="#000000"],.flow-chart [stroke="#000000"] {
stroke:#3f3f3f
}
.sequence-diagram text[stroke="#000000"],.flow-chart text[stroke="#000000"] {
stroke:none
}
.sequence-diagram [fill="#000"],.flow-chart [fill="#000"],.sequence-diagram [fill="#000000"],.flow-chart [fill="#000000"],.sequence-diagram [fill="black"],.flow-chart [fill="black"] {
fill:#3f3f3f
}
ul,ol {
margin-bottom:1.1em
}
ul ul,ol ul,ul ol,ol ol {
margin-bottom:1.1em
}
kbd {
padding:.1em .6em;
border:1px solid rgba(63,63,63,0.25);
-webkit-box-shadow:0 1px 0 rgba(63,63,63,0.25);
box-shadow:0 1px 0 rgba(63,63,63,0.25);
font-size:.7em;
font-family:sans-serif;
background-color:#fff;
color:#333;
border-radius:3px;
display:inline-block;
margin:0 .1em;
white-space:nowrap
}
.toc ul {
list-style-type:none;
margin-bottom:15px
}
.m-todo-item {
list-style: none;
}
pre code {
padding: 0;
color: inherit;
white-space: pre-wrap;
background-color: inherit;
border-radius: 0;
}
</style>
<!-- 该css供自定义样式 -->
<link href="../leanote-markdown.css" rel="stylesheet">
</head>
<body>
<div class="note-container">
<h1 class="title" id="leanote-title">配置指南</h1>
<div class="content-container html" id="content-container">
<!-- 切换 -->
<div class="tab"><a id="tab-markdown">Markdown</a><a id="tab-html">HTML</a></div>
<textarea id="leanote-content-markdown">测试域名:
frontplus.hrjk-p2p.com
usersplus.hrjk-p2p.com
wapplus.hrjk-p2p.com
bigimg.hrjk-p2p.com
apiplus-and.hrjk-p2p.com
apiplus-ios.hrjk-p2p.com
forwardplus.hrjk-p2p.com对外接口连连宝付回调
准生产域名
yuwwwplus.hrjkp2p.com
yuusersplus.hrjkp2p.com
yuwapplus.hrjkp2p.com
yubigimg.hrjkp2p.com
yuapiplus-and.hrjkp2p.com
yuapiplus-ios.hrjkp2p.com
yuforwardplus.hrjkp2p.com
生产环境
www.5262hj.com
users.5262hj.com
wap.5262hj.com
android.5262hj.com
ios.5262hj.com
img.5262hj.com
appdown.5262hj.com
f.5262hj.com
admin.5262hj.com
----------
# 以生产为例
### **1. api**
域名android.5262hj.com ios.5262hj.com
IP192.168.6.21-26
应用路径:/data/htdocs/v/plus
修改配置api-and/Common/Conf/config.php
'IMG_URL'=> 'https://img.5262hj.com', // 图片服务器域名
...
'__PUBLIC__' => 'https://android.5262hj.com',
...
'BAOFOORETURN' =>"https://f.5262hj.com/Payment/baoFooOnlineAsyncNotice",
...
'WAP_URL' => 'https://wap.5262hj.com',
...
'meber_URL'=> 'https://users.5262hj.com',
'ADMIN_URL'=>'http://admin.5262hj.com',
...
'LLPAYRETURN'=>'https://f.5262hj.com/Payment/lianlianAsyncNotice',
...
'WAP_RETURN_URL'=>'https://wap.5262hj.com/rechargePay/PayResult',//WAP支付支付结束后显示页面
...
'oid_partner'=>'201506251000385505',//连连支付正式商户号
'LL_MD5_KEY'=>'201506251000385505SZQHHRHLWJR-20150703',//连连支付正式秘钥
'PC_Domain'=>'https://www.5262hj.com',
'BBS_Domain'=>'http://bbs.5262.com',
...
'READ_URL' => 'http://pmall.yaotv.tvm.cn/open/financial/huaren/order',//天脉真实环境
'TEST_URL' => 'http://qa.pmall.yaotv.tvm.cn/open/financial/huaren/order',//天脉测试环境
'READ_OR_TEST_URL' => 2,//1代表天脉测试环境2代表真实
...
'CONTRACT_DIR' => '/data/run/v/plus/contract',//合同读取目录
'GOME_URL' => 'http://192.168.6.10:8082/hrjk-login/ws/HrjkServiceCxf?wsdl', //>国美统一登录接口请求地址
'MONGODB_HOST'=>'192.168.6.5', //mongo数据库地址
'MONGODB_PORT'=>'37019', //mongo端口
...
//swoole远程服务
'SWOOLE'=>array(
'HOST'=>'192.168.6.43',
'PORT'=>9514,
'TIMEOUT'=>0.5,
),
//异步日志服务
'SWOOLE_LOG'=>array(
'HOST'=>'192.168.6.44',
'PORT'=>9501,
'TIMEOUT'=>0.5,
),
'APPLICATION_ITEM'=>'android-plus',//项目如ios-v2,ios-v1等
'FORWARD_URL' => 'https://f.5262hj.com', //中间层地址
...
'PC_LL_AUTH_PAY'=>'https://cashier.lianlianpay.com/payment/authpay.htm',//连连认证支付地址
'PC_LL_BANK_PAY'=>'https://cashier.lianlianpay.com/payment/bankgateway.htm',//连连支付网关地址
//PC宝付网银支付配置
'BAOFOO_IS_TEST_READ' => 2, //1-宝付网银支付测试 2-宝付网银支付正式
...
'PRODUCT'=>array(
'MemberID' => '1189157',//商户号
'TerminalID'=> "36194",//终端号
'Md5key'=> "azzjncdslzeq745v",//md5密钥KEY
'payUrl'=> "https://gw.baofoo.com/payindex", //借贷混合-正式
),
...
'EXPLAINCONTRACT'=>21,//新增说明书合同 products_data.data_transaction表的tran_id
...
'SYNC_API_URL' => 'https://api-and-13.5262.com',//5262API地址
'FIRST_COUPON_DAY'=>5,//首次提示红包天数限期
数据库配置api-and/Common/Conf/db.conf
<?php
return array (
'DB_TYPE' => 'mysql', // 数据库类型
'DB_HOST' => '192.168.6.5', // 服务器地址
'DB_NAME' => 'system_data', // 数据库名
'DB_USER' => 'admin', // 用户名
'DB_PWD' => 'admin2017COM', // 密码
'DB_PORT' => 3306, // 端口
'DB_PREFIX' => 'data_', // 数据库表前缀
'DB_CHARSET' => 'utf8', // 数据库编码
'DB_DEBUG' => TRUE, // 数据库调试模式 开启后可以记录SQL日志
//Redis Session配置
'SESSION_AUTO_START' => true, // 是否自动开启Session
'SESSION_TYPE' => 'Redis', //session类型
'SESSION_PERSISTENT' => 0, //是否长连接(对于php来说0和1都一样)
'SESSION_CACHE_TIME' => 1, //连接超时时间(秒)
'SESSION_EXPIRE' => 0, //session有效期(单位:秒) 0表示永久缓存
'SESSION_PREFIX' => 'app_', //session前缀
'SESSION_REDIS_HOST' => '192.168.6.5', //分布式Redis,默认第一个为主服务器
'SESSION_REDIS_PORT' => '7379', //端口,如果相同只填一个,用英文逗号分隔
'SYNC_SESSION_REDIS_HOST' => '192.168.6.6', //分布式Redis,默认第一个为主服务器
'SYNC_SESSION_REDIS_PORT' => '6379', //端口,如果相同只填一个,用英文逗号分隔
// 'SESSION_REDIS_AUTH' => 'redis123', //Redis auth认证(密钥中不能有逗号),如果相同只填一个,用英文逗号分隔
);
?>
短信配置api-and/Home/Common/msg.class.php
protected static $api_url = 'http://192.168.6.5:9909/api/sendsms';//api地址
- ***合同需要挂载api主机和swoole9504主机***
- 合同左上角的logo为api-and/Core/Library/Vendor/tcpdf/examples/images/logo.png
----------
### **2. forward**
域名f.5262hj.com
IP192.168.6.21-26
应用路径:/data/htdocs/v/plus
修改配置forward/conf/application.ini
...
itemname = forwardplus
...
; ================= 生产环境 =================
[product : common]
;Redis
redis_host = 192.168.6.5
redis_port = 7379
;api地址
api_url = https://android.5262hj.com/
;前端用户中心地址
member_URL = https://users.5262hj.com/
www_URL = https://www.5262hj.com/
;swoole log server
log_server_host = 192.168.6.44
log_server_port = 9501
引用配置域: forward/public/index.php
$app = new Yaf\Application(APP_PATH.'/conf/application.ini', 'product');
----------
### **3. wap**
域名wap.5262hj.com
IP192.168.6.31-34
应用路径:/data/htdocs/v/plus
修改配置wap/Common/Conf/config.php
'IMG_URL' => 'https://img.5262hj.com', // 图片服务器域名
'API_URI' => 'https://android.5262hj.com/',//内部数据请求接口
'__PUBLIC__' => 'https://wap.5262hj.com',
'WAP_AUTH_PAY'=>'https://wap.lianlianpay.com/authpay.htm',//连连认证支付接口
'APP_ID' => 'wx78bd6a6b61f2ce23', //微信公众号appid
'APP_SECRET' => 'af0e695a782536f0c69e767532737c6e', //微信secret
'HZ_PARTOOK_URL' => 'http://www.huazhongtimes.com/imp/activityEntryController!initForjoin.action?activityId=88&express=bsht&authType=0&authRedirec=1',
'HZ_LOTTERY_URL' => 'http://www.huazhongtimes.com/imp/m-client/app/award/module4/views/index.html?orderId=%s&token=%s&id=88&pic=hrjr2',
数据库配置wap/Common/Conf/db.php
<?php
return array (
//Redis Session配置
'SESSION_AUTO_START' => true, // 是否自动开启Session
'SESSION_TYPE' => 'Redis', //session类型
'SESSION_PERSISTENT' => 0, //是否长连接(对于php来说0和1都一样)
'SESSION_CACHE_TIME' => 1, //连接超时时间(秒)
'SESSION_EXPIRE' => 0, //session有效期(单位:秒) 0表示永久缓存
'SESSION_PREFIX' => 'wap2_', //session前缀
'SESSION_REDIS_HOST' => '192.168.6.5', //分布式Redis,默认第一个为主服务器
'SESSION_REDIS_PORT' => '7379', //端口,如果相同只填一个,用英文逗号分隔
// 'SESSION_REDIS_AUTH' => 'redis123', //Redis auth认证(密钥中不能有逗号),如果相同只填一个,用英文逗号分隔
);
?>
----------
### **4. swoole**
IP192.168.6.43 192.168.6.45
应用路径:/data/htdocs/v/plus
- Swoole_9511
修改配置Swoole_9511/Common/Conf/config.php
'PORT'=>9511,
...
'LogServer'=>array(
'HOST'=>'192.168.6.44',//异步日志服务器IP
'PORT'=>9501,
'TIMEOUT'=>0.5
),
'ItemName'=>'plusSWOOLE',//项目名称
'API_URL' => 'https://android.5262hj.com/v2',//v2接口地址
'MEMBER_URL' => 'https://users.5262hj.com',//用户中心地址
'CONTRACT' => array(
'JAVA_SERVICE' => 'http://192.168.6.45',//java服务地址
'JAVA_SERVICE_PORT' => '8080',//java服务端口
//'ITSM_GETAPIINFO_URL' => 'http://121.40.164.61:8080/tgmonitor/rest/app!getAPIInfo2',//e签宝接口地址测试
'ITSM_GETAPIINFO_URL' => 'http://itsm.tsign.cn/tgmonitor/rest/app!getAPIInfo2',//e签宝接口地址正式
'EVR_TIMEURl' => 'http://openapi2.tsign.cn:8082/timestamp/rest/v1/server/get',//e签宝获取时间戳正式环境地址
'CONTRACT_DIR' => '/data/htdocs/v/plus/contract',//合同保存目录
'SEAL_CONTRACT_DIR' => '/data/htdocs/v/plus/contract',//合同读取目录
'TIMEVALE_MODE' => 'package',//e签宝请求签名方式
'CONTENT_TYPE_URL' =>'application/json',//e签宝请求url报文数据格式
'ALGORITHM' => 'HmacSHA256',//e签宝请求签名算法
'CONTENT_TYPE' =>'application/octet-stream',//e签宝请求报文数据格式
//'EVR_URl' => 'http://smlcunzheng.tsign.cn:8083/evi-service/evidence/v1/preservation/original/url',//e签宝文档保全测试环境地址
'EVR_URl' => 'http://evislb.tsign.cn:8080/evi-service/evidence/v1/preservation/original/url',//e签宝文档保全正式环境地址
//'PROJECT_ID' => '1111563852',//e签宝项目编号
'PROJECT_ID' => '1111564358',//e签宝项目编号
//'PROJECT_SECRET' => 'd76192b25a88a6d58d06e87b186be65c',//e签宝项目校验码
'PROJECT_SECRET' => 'cb54ca81e9186bb4a28fc5bdf5f29349',//e签宝项目校验码
'COMPANY_LEGAL' => array(
/*'LEGAL_NAME' => '赵财强',//法人姓名
'LEGAL_IDCARD' => '44052419691007367X',//法人身份证
'LEGAL_MOBILE' => '13242011615',//法人手机号 */
'LEGAL_NAME' => '林耿标',//法人姓名
'LEGAL_IDCARD' => '440582198503120654',//法人身份证
'LEGAL_MOBILE' => '13715193057',//法人手机号
),
数据库配置Swoole_9511/Common/Conf/db.php
<?php
return array (
'DB_TYPE' => 'mysql', // 数据库类型
'DB_HOST' => '192.168.6.5', // 服务器地址
'DB_NAME' => 'system_data', // 数据库名
'DB_USER' => 'admin', // 用户名
'DB_PWD' => 'admin2017COM', // 密码
'DB_PORT' => 3306, // 端口
'DB_PREFIX' => 'data_', // 数据库表前缀
'DB_CHARSET' => 'utf8', // 数据库编码
'DB_DEBUG' => TRUE, // 数据库调试模式 开启后可以记录SQL日志
//Redis Session配置
'SESSION_AUTO_START' => true, // 是否自动开启Session
'SESSION_TYPE' => 'Redis', //session类型
'SESSION_PERSISTENT' => 0, //是否长连接(对于php来说0和1都一样)
'SESSION_CACHE_TIME' => 1, //连接超时时间(秒)
'SESSION_EXPIRE' => 0, //session有效期(单位:秒) 0表示永久缓存
'SESSION_PREFIX' => 'app_', //session前缀
'SESSION_REDIS_HOST' => '192.168.6.5', //分布式Redis,默认第一个为主服务器
'SESSION_REDIS_PORT' => '7379', //端口,如果相同只填一个,用英文逗号分隔
// 'SESSION_REDIS_AUTH' => 'redis123', //Redis auth认证(密钥中不能有逗号),如果相同只填一个,用英文逗号分隔
'MONGODB_HOST' => '192.168.6.71',//mongodb服务器地址
'MONGODB_PORT' => '27017',//mongodb服务器端口
);
?>
短信配置Swoole_9511/Home/Common/msg.class.php
protected static $api_url = 'http://192.168.6.5:9909/api/sendsms';//api地址
- Swoole_9514
与Swoole_9511配置区别不大主要区别如下
'PORT'=>9511,
'ItemName'=>'plusSWOOLE',//项目名称
----------
### **5. admin**
域名admin.5262hj.com
IP192.168.6.41-42
应用路径:/data/htdocs/v/plus
修改配置admin/wlib/do/config/config.php
...
'READ_URL' => 'http://pmall.yaotv.tvm.cn/open/financial/huaren/order',//天脉真实环境
'TEST_URL' => 'http://qa.pmall.yaotv.tvm.cn/open/financial/huaren/order',//天脉测试环境
'READ_OR_TEST_URL' => 2,//1代表天脉测试环境2代表真实
'encryptKey'=>'e0dd544dc164102767c9f487430407a1',
...
'FBABA_UID' => '1316',//测试用1107 正式环境用1316
...
'XINMEI_URL' => 2,//1代表信美接口测试环境2代表信美接口真实
...
数据库配置mysql-1wlib/modules/database/config/database.php
<?php defined('SYSPATH') or die('No direct access allowed.');
return array
(
//默认为主数据库服务器(写)
'default' => array
(
'type' => 'mysql',
'connection' => array(
'hostname' => '192.168.6.5:3306',
'database' => 'system_data',
'username' => 'admin',
'password' => 'admin2017COM',
'persistent' => FALSE,
),
'table_prefix' => 'data_',
'charset' => 'utf8',
'caching' => FALSE,
'profiling' => TRUE,
),
//以下为从数据库服务器(读)
'slave' => array
(
'type' => 'mysql',
'connection' => array(
'hostname' => '192.168.6.5:3306',
'database' => 'system_data',
'username' => 'admin',
'password' => 'admin2017COM',
'persistent' => FALSE,
),
'table_prefix' => 'data_',
'charset' => 'utf8',
'caching' => FALSE,
'profiling' => TRUE,
),
'slave1' => array
(
'type' => 'mysql',
'connection' => array(
'hostname' => '192.168.6.5:3306',
'database' => 'system_data',
'username' => 'admin',
'password' => 'admin2017COM',
'persistent' => FALSE,
),
'table_prefix' => 'data_',
'charset' => 'utf8',
'caching' => FALSE,
'profiling' => TRUE,
),
'slave2' => array(
'type' => 'mysql',
'connection' => array(
'hostname' => '192.168.6.5:3306',
'database' => 'system_data',
'username' => 'admin',
'password' => 'admin2017COM',
'persistent' => FALSE,
),
'table_prefix' => 'data_',
'charset' => 'utf8',
'caching' => FALSE,
'profiling' => TRUE,
),
);
数据库配置mysql-2admin/wlib/do/lib/cls_mysql.php
...
function __construct($dbhost='192.168.6.5:3306', $dbuser='admin', $dbpw='admin2017COM', $dbname = 'accounts_data', $charset = 'utf-8', $pconnect = 0, $quiet = 0)
...
function cls_mysql($dbhost='192.168.6.5:3306', $dbuser='admin', $dbpw='admin2017COM', $dbname = 'accounts_data', $charset = 'utf-8', $pconnect = 0, $quiet = 0)
...
数据库配置redis admin/wlib/modules/database/config/redis.php
return array(
'host' => '192.168.6.5',
'port' => '7379',
'timeout' => 1,//连接超时时间(秒)
);
数据库配置mongodbadmin/wlib/modules/database/config/mangodb.php
<?php
return array(
'default' => array(
'connection' => array(
'hostnames' => '192.168.6.5:37019',
),
'profiling' => FALSE
),
'slave1' => array(
'connection' => array(
'hostnames' => '192.168.6.5:37019',
),
'profiling' => FALSE
),
'slave2' => array(
'connection' => array(
'hostnames' => '192.168.6.5:37019',
),
'profiling' => FALSE
),
);
### **6. www users**
域名 www.5262hj.com users.5262hj.com
***说明:前端是编译后,生成的文件,修改配置需要前端开发配置并编译***
新建一个server在nginx中 </textarea>
<!-- markdown -->
<pre class="content-markdown">测试域名:
frontplus.hrjk-p2p.com
usersplus.hrjk-p2p.com
wapplus.hrjk-p2p.com
bigimg.hrjk-p2p.com
apiplus-and.hrjk-p2p.com
apiplus-ios.hrjk-p2p.com
forwardplus.hrjk-p2p.com对外接口连连宝付回调
准生产域名
yuwwwplus.hrjkp2p.com
yuusersplus.hrjkp2p.com
yuwapplus.hrjkp2p.com
yubigimg.hrjkp2p.com
yuapiplus-and.hrjkp2p.com
yuapiplus-ios.hrjkp2p.com
yuforwardplus.hrjkp2p.com
生产环境
www.5262hj.com
users.5262hj.com
wap.5262hj.com
android.5262hj.com
ios.5262hj.com
img.5262hj.com
appdown.5262hj.com
f.5262hj.com
admin.5262hj.com
----------
# 以生产为例
### **1. api**
域名android.5262hj.com ios.5262hj.com
IP192.168.6.21-26
应用路径:/data/htdocs/v/plus
修改配置api-and/Common/Conf/config.php
'IMG_URL'=> 'https://img.5262hj.com', // 图片服务器域名
...
'__PUBLIC__' => 'https://android.5262hj.com',
...
'BAOFOORETURN' =>"https://f.5262hj.com/Payment/baoFooOnlineAsyncNotice",
...
'WAP_URL' => 'https://wap.5262hj.com',
...
'meber_URL'=> 'https://users.5262hj.com',
'ADMIN_URL'=>'http://admin.5262hj.com',
...
'LLPAYRETURN'=>'https://f.5262hj.com/Payment/lianlianAsyncNotice',
...
'WAP_RETURN_URL'=>'https://wap.5262hj.com/rechargePay/PayResult',//WAP支付支付结束后显示页面
...
'oid_partner'=>'201506251000385505',//连连支付正式商户号
'LL_MD5_KEY'=>'201506251000385505SZQHHRHLWJR-20150703',//连连支付正式秘钥
'PC_Domain'=>'https://www.5262hj.com',
'BBS_Domain'=>'http://bbs.5262.com',
...
'READ_URL' => 'http://pmall.yaotv.tvm.cn/open/financial/huaren/order',//天脉真实环境
'TEST_URL' => 'http://qa.pmall.yaotv.tvm.cn/open/financial/huaren/order',//天脉测试环境
'READ_OR_TEST_URL' => 2,//1代表天脉测试环境2代表真实
...
'CONTRACT_DIR' => '/data/run/v/plus/contract',//合同读取目录
'GOME_URL' => 'http://192.168.6.10:8082/hrjk-login/ws/HrjkServiceCxf?wsdl', //>国美统一登录接口请求地址
'MONGODB_HOST'=>'192.168.6.5', //mongo数据库地址
'MONGODB_PORT'=>'37019', //mongo端口
...
//swoole远程服务
'SWOOLE'=>array(
'HOST'=>'192.168.6.43',
'PORT'=>9514,
'TIMEOUT'=>0.5,
),
//异步日志服务
'SWOOLE_LOG'=>array(
'HOST'=>'192.168.6.44',
'PORT'=>9501,
'TIMEOUT'=>0.5,
),
'APPLICATION_ITEM'=>'android-plus',//项目如ios-v2,ios-v1等
'FORWARD_URL' => 'https://f.5262hj.com', //中间层地址
...
'PC_LL_AUTH_PAY'=>'https://cashier.lianlianpay.com/payment/authpay.htm',//连连认证支付地址
'PC_LL_BANK_PAY'=>'https://cashier.lianlianpay.com/payment/bankgateway.htm',//连连支付网关地址
//PC宝付网银支付配置
'BAOFOO_IS_TEST_READ' => 2, //1-宝付网银支付测试 2-宝付网银支付正式
...
'PRODUCT'=>array(
'MemberID' => '1189157',//商户号
'TerminalID'=> "36194",//终端号
'Md5key'=> "azzjncdslzeq745v",//md5密钥KEY
'payUrl'=> "https://gw.baofoo.com/payindex", //借贷混合-正式
),
...
'EXPLAINCONTRACT'=>21,//新增说明书合同 products_data.data_transaction表的tran_id
...
'SYNC_API_URL' => 'https://api-and-13.5262.com',//5262API地址
'FIRST_COUPON_DAY'=>5,//首次提示红包天数限期
数据库配置api-and/Common/Conf/db.conf
<?php
return array (
'DB_TYPE' => 'mysql', // 数据库类型
'DB_HOST' => '192.168.6.5', // 服务器地址
'DB_NAME' => 'system_data', // 数据库名
'DB_USER' => 'admin', // 用户名
'DB_PWD' => 'admin2017COM', // 密码
'DB_PORT' => 3306, // 端口
'DB_PREFIX' => 'data_', // 数据库表前缀
'DB_CHARSET' => 'utf8', // 数据库编码
'DB_DEBUG' => TRUE, // 数据库调试模式 开启后可以记录SQL日志
//Redis Session配置
'SESSION_AUTO_START' => true, // 是否自动开启Session
'SESSION_TYPE' => 'Redis', //session类型
'SESSION_PERSISTENT' => 0, //是否长连接(对于php来说0和1都一样)
'SESSION_CACHE_TIME' => 1, //连接超时时间(秒)
'SESSION_EXPIRE' => 0, //session有效期(单位:秒) 0表示永久缓存
'SESSION_PREFIX' => 'app_', //session前缀
'SESSION_REDIS_HOST' => '192.168.6.5', //分布式Redis,默认第一个为主服务器
'SESSION_REDIS_PORT' => '7379', //端口,如果相同只填一个,用英文逗号分隔
'SYNC_SESSION_REDIS_HOST' => '192.168.6.6', //分布式Redis,默认第一个为主服务器
'SYNC_SESSION_REDIS_PORT' => '6379', //端口,如果相同只填一个,用英文逗号分隔
// 'SESSION_REDIS_AUTH' => 'redis123', //Redis auth认证(密钥中不能有逗号),如果相同只填一个,用英文逗号分隔
);
?>
短信配置api-and/Home/Common/msg.class.php
protected static $api_url = 'http://192.168.6.5:9909/api/sendsms';//api地址
- ***合同需要挂载api主机和swoole9504主机***
- 合同左上角的logo为api-and/Core/Library/Vendor/tcpdf/examples/images/logo.png
----------
### **2. forward**
域名f.5262hj.com
IP192.168.6.21-26
应用路径:/data/htdocs/v/plus
修改配置forward/conf/application.ini
...
itemname = forwardplus
...
; ================= 生产环境 =================
[product : common]
;Redis
redis_host = 192.168.6.5
redis_port = 7379
;api地址
api_url = https://android.5262hj.com/
;前端用户中心地址
member_URL = https://users.5262hj.com/
www_URL = https://www.5262hj.com/
;swoole log server
log_server_host = 192.168.6.44
log_server_port = 9501
引用配置域: forward/public/index.php
$app = new Yaf\Application(APP_PATH.'/conf/application.ini', 'product');
----------
### **3. wap**
域名wap.5262hj.com
IP192.168.6.31-34
应用路径:/data/htdocs/v/plus
修改配置wap/Common/Conf/config.php
'IMG_URL' => 'https://img.5262hj.com', // 图片服务器域名
'API_URI' => 'https://android.5262hj.com/',//内部数据请求接口
'__PUBLIC__' => 'https://wap.5262hj.com',
'WAP_AUTH_PAY'=>'https://wap.lianlianpay.com/authpay.htm',//连连认证支付接口
'APP_ID' => 'wx78bd6a6b61f2ce23', //微信公众号appid
'APP_SECRET' => 'af0e695a782536f0c69e767532737c6e', //微信secret
'HZ_PARTOOK_URL' => 'http://www.huazhongtimes.com/imp/activityEntryController!initForjoin.action?activityId=88&express=bsht&authType=0&authRedirec=1',
'HZ_LOTTERY_URL' => 'http://www.huazhongtimes.com/imp/m-client/app/award/module4/views/index.html?orderId=%s&token=%s&id=88&pic=hrjr2',
数据库配置wap/Common/Conf/db.php
<?php
return array (
//Redis Session配置
'SESSION_AUTO_START' => true, // 是否自动开启Session
'SESSION_TYPE' => 'Redis', //session类型
'SESSION_PERSISTENT' => 0, //是否长连接(对于php来说0和1都一样)
'SESSION_CACHE_TIME' => 1, //连接超时时间(秒)
'SESSION_EXPIRE' => 0, //session有效期(单位:秒) 0表示永久缓存
'SESSION_PREFIX' => 'wap2_', //session前缀
'SESSION_REDIS_HOST' => '192.168.6.5', //分布式Redis,默认第一个为主服务器
'SESSION_REDIS_PORT' => '7379', //端口,如果相同只填一个,用英文逗号分隔
// 'SESSION_REDIS_AUTH' => 'redis123', //Redis auth认证(密钥中不能有逗号),如果相同只填一个,用英文逗号分隔
);
?>
----------
### **4. swoole**
IP192.168.6.43 192.168.6.45
应用路径:/data/htdocs/v/plus
- Swoole_9511
修改配置Swoole_9511/Common/Conf/config.php
'PORT'=>9511,
...
'LogServer'=>array(
'HOST'=>'192.168.6.44',//异步日志服务器IP
'PORT'=>9501,
'TIMEOUT'=>0.5
),
'ItemName'=>'plusSWOOLE',//项目名称
'API_URL' => 'https://android.5262hj.com/v2',//v2接口地址
'MEMBER_URL' => 'https://users.5262hj.com',//用户中心地址
'CONTRACT' => array(
'JAVA_SERVICE' => 'http://192.168.6.45',//java服务地址
'JAVA_SERVICE_PORT' => '8080',//java服务端口
//'ITSM_GETAPIINFO_URL' => 'http://121.40.164.61:8080/tgmonitor/rest/app!getAPIInfo2',//e签宝接口地址测试
'ITSM_GETAPIINFO_URL' => 'http://itsm.tsign.cn/tgmonitor/rest/app!getAPIInfo2',//e签宝接口地址正式
'EVR_TIMEURl' => 'http://openapi2.tsign.cn:8082/timestamp/rest/v1/server/get',//e签宝获取时间戳正式环境地址
'CONTRACT_DIR' => '/data/htdocs/v/plus/contract',//合同保存目录
'SEAL_CONTRACT_DIR' => '/data/htdocs/v/plus/contract',//合同读取目录
'TIMEVALE_MODE' => 'package',//e签宝请求签名方式
'CONTENT_TYPE_URL' =>'application/json',//e签宝请求url报文数据格式
'ALGORITHM' => 'HmacSHA256',//e签宝请求签名算法
'CONTENT_TYPE' =>'application/octet-stream',//e签宝请求报文数据格式
//'EVR_URl' => 'http://smlcunzheng.tsign.cn:8083/evi-service/evidence/v1/preservation/original/url',//e签宝文档保全测试环境地址
'EVR_URl' => 'http://evislb.tsign.cn:8080/evi-service/evidence/v1/preservation/original/url',//e签宝文档保全正式环境地址
//'PROJECT_ID' => '1111563852',//e签宝项目编号
'PROJECT_ID' => '1111564358',//e签宝项目编号
//'PROJECT_SECRET' => 'd76192b25a88a6d58d06e87b186be65c',//e签宝项目校验码
'PROJECT_SECRET' => 'cb54ca81e9186bb4a28fc5bdf5f29349',//e签宝项目校验码
'COMPANY_LEGAL' => array(
/*'LEGAL_NAME' => '赵财强',//法人姓名
'LEGAL_IDCARD' => '44052419691007367X',//法人身份证
'LEGAL_MOBILE' => '13242011615',//法人手机号 */
'LEGAL_NAME' => '林耿标',//法人姓名
'LEGAL_IDCARD' => '440582198503120654',//法人身份证
'LEGAL_MOBILE' => '13715193057',//法人手机号
),
数据库配置Swoole_9511/Common/Conf/db.php
<?php
return array (
'DB_TYPE' => 'mysql', // 数据库类型
'DB_HOST' => '192.168.6.5', // 服务器地址
'DB_NAME' => 'system_data', // 数据库名
'DB_USER' => 'admin', // 用户名
'DB_PWD' => 'admin2017COM', // 密码
'DB_PORT' => 3306, // 端口
'DB_PREFIX' => 'data_', // 数据库表前缀
'DB_CHARSET' => 'utf8', // 数据库编码
'DB_DEBUG' => TRUE, // 数据库调试模式 开启后可以记录SQL日志
//Redis Session配置
'SESSION_AUTO_START' => true, // 是否自动开启Session
'SESSION_TYPE' => 'Redis', //session类型
'SESSION_PERSISTENT' => 0, //是否长连接(对于php来说0和1都一样)
'SESSION_CACHE_TIME' => 1, //连接超时时间(秒)
'SESSION_EXPIRE' => 0, //session有效期(单位:秒) 0表示永久缓存
'SESSION_PREFIX' => 'app_', //session前缀
'SESSION_REDIS_HOST' => '192.168.6.5', //分布式Redis,默认第一个为主服务器
'SESSION_REDIS_PORT' => '7379', //端口,如果相同只填一个,用英文逗号分隔
// 'SESSION_REDIS_AUTH' => 'redis123', //Redis auth认证(密钥中不能有逗号),如果相同只填一个,用英文逗号分隔
'MONGODB_HOST' => '192.168.6.71',//mongodb服务器地址
'MONGODB_PORT' => '27017',//mongodb服务器端口
);
?>
短信配置Swoole_9511/Home/Common/msg.class.php
protected static $api_url = 'http://192.168.6.5:9909/api/sendsms';//api地址
- Swoole_9514
与Swoole_9511配置区别不大主要区别如下
'PORT'=>9511,
'ItemName'=>'plusSWOOLE',//项目名称
----------
### **5. admin**
域名admin.5262hj.com
IP192.168.6.41-42
应用路径:/data/htdocs/v/plus
修改配置admin/wlib/do/config/config.php
...
'READ_URL' => 'http://pmall.yaotv.tvm.cn/open/financial/huaren/order',//天脉真实环境
'TEST_URL' => 'http://qa.pmall.yaotv.tvm.cn/open/financial/huaren/order',//天脉测试环境
'READ_OR_TEST_URL' => 2,//1代表天脉测试环境2代表真实
'encryptKey'=>'e0dd544dc164102767c9f487430407a1',
...
'FBABA_UID' => '1316',//测试用1107 正式环境用1316
...
'XINMEI_URL' => 2,//1代表信美接口测试环境2代表信美接口真实
...
数据库配置mysql-1wlib/modules/database/config/database.php
<?php defined('SYSPATH') or die('No direct access allowed.');
return array
(
//默认为主数据库服务器(写)
'default' => array
(
'type' => 'mysql',
'connection' => array(
'hostname' => '192.168.6.5:3306',
'database' => 'system_data',
'username' => 'admin',
'password' => 'admin2017COM',
'persistent' => FALSE,
),
'table_prefix' => 'data_',
'charset' => 'utf8',
'caching' => FALSE,
'profiling' => TRUE,
),
//以下为从数据库服务器(读)
'slave' => array
(
'type' => 'mysql',
'connection' => array(
'hostname' => '192.168.6.5:3306',
'database' => 'system_data',
'username' => 'admin',
'password' => 'admin2017COM',
'persistent' => FALSE,
),
'table_prefix' => 'data_',
'charset' => 'utf8',
'caching' => FALSE,
'profiling' => TRUE,
),
'slave1' => array
(
'type' => 'mysql',
'connection' => array(
'hostname' => '192.168.6.5:3306',
'database' => 'system_data',
'username' => 'admin',
'password' => 'admin2017COM',
'persistent' => FALSE,
),
'table_prefix' => 'data_',
'charset' => 'utf8',
'caching' => FALSE,
'profiling' => TRUE,
),
'slave2' => array(
'type' => 'mysql',
'connection' => array(
'hostname' => '192.168.6.5:3306',
'database' => 'system_data',
'username' => 'admin',
'password' => 'admin2017COM',
'persistent' => FALSE,
),
'table_prefix' => 'data_',
'charset' => 'utf8',
'caching' => FALSE,
'profiling' => TRUE,
),
);
数据库配置mysql-2admin/wlib/do/lib/cls_mysql.php
...
function __construct($dbhost='192.168.6.5:3306', $dbuser='admin', $dbpw='admin2017COM', $dbname = 'accounts_data', $charset = 'utf-8', $pconnect = 0, $quiet = 0)
...
function cls_mysql($dbhost='192.168.6.5:3306', $dbuser='admin', $dbpw='admin2017COM', $dbname = 'accounts_data', $charset = 'utf-8', $pconnect = 0, $quiet = 0)
...
数据库配置redis admin/wlib/modules/database/config/redis.php
return array(
'host' => '192.168.6.5',
'port' => '7379',
'timeout' => 1,//连接超时时间(秒)
);
数据库配置mongodbadmin/wlib/modules/database/config/mangodb.php
<?php
return array(
'default' => array(
'connection' => array(
'hostnames' => '192.168.6.5:37019',
),
'profiling' => FALSE
),
'slave1' => array(
'connection' => array(
'hostnames' => '192.168.6.5:37019',
),
'profiling' => FALSE
),
'slave2' => array(
'connection' => array(
'hostnames' => '192.168.6.5:37019',
),
'profiling' => FALSE
),
);
### **6. www users**
域名 www.5262hj.com users.5262hj.com
***说明:前端是编译后,生成的文件,修改配置需要前端开发配置并编译***
新建一个server在nginx中 </pre>
<!-- html -->
<div class="content-html" id="leanote-content-html"></div>
</div>
</div>
<!-- 该js供其它处理 -->
<script src="../leanote-markdown.js"></script>
<script src="http://leanote.github.io/markdown-to-html/markdown-to-html.min.js"></script>
<script>
function init() {
markdownToHtml(document.getElementById('leanote-content-markdown').value, document.getElementById('leanote-content-html'), function(html) {
// 解析后执行
if(window.markdownParsed) {
window.markdownParsed(html);
}
});
var $m = document.getElementById('tab-markdown');
var $h = document.getElementById('tab-html');
var $cc = document.getElementById('content-container');
function toggleToHtml(isToHtml) {
$cc.className = isToHtml ? 'content-container html' : 'content-container';
}
$m.addEventListener('click', function() {
toggleToHtml(false);
});
$h.addEventListener('click', function() {
toggleToHtml(true);
});
}
// 如果不要自动解析html, notParseMarkdown在leanote-markdown.js中定义
if(!window.notParseMarkdown) {
init();
}
</script>
</body>
</html>