Showing
1 changed file
with
7 additions
and
115 deletions
@@ -10,25 +10,15 @@ const pkg = require('../package.json'); | @@ -10,25 +10,15 @@ const pkg = require('../package.json'); | ||
10 | const isProduction = process.env.NODE_ENV === 'production'; | 10 | const isProduction = process.env.NODE_ENV === 'production'; |
11 | const isTest = process.env.NODE_ENV === 'test'; | 11 | const isTest = process.env.NODE_ENV === 'test'; |
12 | 12 | ||
13 | -const domains = { | ||
14 | - api: 'http://api-test3.yohops.com:9999/', | ||
15 | - service: 'http://service-test3.yohops.com:9999/', | ||
16 | - singleApi: 'http://api-test3.yohops.com:9999/', | ||
17 | - global: 'http://global-test-soa.yohops.com:9999', | ||
18 | - liveApi: 'http://testapi.live.yohops.com:9999/', | ||
19 | - imSocket: 'ws://socket.yohobuy.com:10240', | ||
20 | - imCs: 'http://im.yohobuy.com/api', | ||
21 | - platformApi: 'http://192.168.102.48:8088/' | ||
22 | -}; | ||
23 | - | ||
24 | module.exports = { | 13 | module.exports = { |
25 | app: 'h5', | 14 | app: 'h5', |
26 | appVersion: '5.8.0', // 调用api的版本 | 15 | appVersion: '5.8.0', // 调用api的版本 |
27 | port: 6006, | 16 | port: 6006, |
28 | - siteUrl: '//m.yohobuy.com', | ||
29 | - assetUrl: '//127.0.0.1:5001', | ||
30 | - testCode: 'yoho4946abcdef#$%&!@', | ||
31 | - domains: domains, | 17 | + domains: { |
18 | + api: 'http://api-test3.yohops.com:9999/', | ||
19 | + service: 'http://service-test3.yohops.com:9999/', | ||
20 | + singleApi: 'http://api-test3.yohops.com:9999/' | ||
21 | + }, | ||
32 | corsAllowOrigin: [ | 22 | corsAllowOrigin: [ |
33 | 'http://localhost:8081', | 23 | 'http://localhost:8081', |
34 | 'http://localhost:63342' | 24 | 'http://localhost:63342' |
@@ -65,35 +55,6 @@ module.exports = { | @@ -65,35 +55,6 @@ module.exports = { | ||
65 | prettyPrint: true | 55 | prettyPrint: true |
66 | } | 56 | } |
67 | }, | 57 | }, |
68 | - thirdLogin: { | ||
69 | - wechat: { | ||
70 | - appID: 'wx75e5a7c0c88e45c2', | ||
71 | - appSecret: 'ce21ae4a3f93852279175a167e54509b' | ||
72 | - } | ||
73 | - }, | ||
74 | - zookeeperServer: '127.0.0.1:2181', | ||
75 | - maxQps: 1200, | ||
76 | - geetestJs: '//static.geetest.com/static/tools/gt.js', | ||
77 | - jsSdk: '//cdn.yoho.cn/js-sdk/1.2.2/jssdk.js', | ||
78 | - redis: { | ||
79 | - connect: { | ||
80 | - host: '127.0.0.1', | ||
81 | - port: '6379', | ||
82 | - retry_strategy(options) { | ||
83 | - if (options.error && options.error.code === 'ECONNREFUSED') { | ||
84 | - console.log('redis连接不成功'); | ||
85 | - } | ||
86 | - if (options.total_retry_time > 1000 * 60 * 60 * 6) { | ||
87 | - console.log('redis连接超时'); | ||
88 | - return; | ||
89 | - } | ||
90 | - if (options.attempt > 10) { | ||
91 | - return 1000 * 60 * 60 * 0.5; | ||
92 | - } | ||
93 | - return Math.min(options.attempt * 100, 1000); | ||
94 | - } | ||
95 | - } | ||
96 | - }, | ||
97 | mysql: { | 58 | mysql: { |
98 | connect: { | 59 | connect: { |
99 | host: 'localhost', | 60 | host: 'localhost', |
@@ -118,11 +79,8 @@ if (isProduction) { | @@ -118,11 +79,8 @@ if (isProduction) { | ||
118 | api: 'http://api.yoho.yohoops.org/', | 79 | api: 'http://api.yoho.yohoops.org/', |
119 | service: 'http://service.yoho.yohoops.org/', | 80 | service: 'http://service.yoho.yohoops.org/', |
120 | global: 'http://api-global.yohobuy.com', | 81 | global: 'http://api-global.yohobuy.com', |
121 | - store: '', // 线上域名尚未确定 | ||
122 | liveApi: 'http://api.live.yoho.cn/', | 82 | liveApi: 'http://api.live.yoho.cn/', |
123 | singleApi: 'http://single.yoho.cn/', | 83 | singleApi: 'http://single.yoho.cn/', |
124 | - imSocket: 'wss://imsocket.yohobuy.com:443', | ||
125 | - imCs: 'https://imhttp.yohobuy.com/api', | ||
126 | platformApi: 'http://api.platform.yohoops.org' | 84 | platformApi: 'http://api.platform.yohoops.org' |
127 | }, | 85 | }, |
128 | corsAllowOrigin: ['http://ad.yoho.cn', 'https://ad.yoho.cn'], | 86 | corsAllowOrigin: ['http://ad.yoho.cn', 'https://ad.yoho.cn'], |
@@ -135,51 +93,7 @@ if (isProduction) { | @@ -135,51 +93,7 @@ if (isProduction) { | ||
135 | timeout: 1000, | 93 | timeout: 1000, |
136 | retries: 0 | 94 | retries: 0 |
137 | }, | 95 | }, |
138 | - useCache: true, | ||
139 | - interfaceShunt: { | ||
140 | - open: false, | ||
141 | - url: 'http://123.206.2.55/strategy' | ||
142 | - }, | ||
143 | - zookeeperServer: 'web.zookeeper.yohoops.org:2181', | ||
144 | - alipayConfig: { | ||
145 | - payUrl: 'https://mapi.alipay.com/gateway.do', | ||
146 | - service: 'alipay.wap.create.direct.pay.by.user', | ||
147 | - partner: '2088701661478015', | ||
148 | - inputCharset: 'utf-8', | ||
149 | - notifyUrl: 'http://service.yoho.cn/payment/alipay_notify', | ||
150 | - returnUrl: '/shopping/pay/aliwapreturn', | ||
151 | - signType: 'MD5', | ||
152 | - paymentType: '1', | ||
153 | - alipayKey: 'kcxawi9bb07mzh0aq2wcirsf9znusobw', | ||
154 | - sellerMail: 'zfb@yoho.cn', | ||
155 | - merchantUrl: 'http://m.yohobuy.com/home/orderDetail?order_code=' | ||
156 | - }, | ||
157 | - WxPayConfig: { | ||
158 | - appId: 'wx75e5a7c0c88e45c2', | ||
159 | - mchId: '1227694201', | ||
160 | - key: '7e6f3307b64cc87c79c472814b88f7fb', | ||
161 | - appSecret: 'ce21ae4a3f93852279175a167e54509b', | ||
162 | - notifyUrl: 'http://service.yoho.cn/payment/weixin_notify', | ||
163 | - }, | ||
164 | - redis: { | ||
165 | - connect: { | ||
166 | - host: 'web.redis.yohoops.org' | ||
167 | - }, | ||
168 | - port: '6379', | ||
169 | - retry_strategy(options) { | ||
170 | - if (options.error && options.error.code === 'ECONNREFUSED') { | ||
171 | - console.log('redis连接不成功'); | ||
172 | - } | ||
173 | - if (options.total_retry_time > 1000 * 60 * 60 * 6) { | ||
174 | - console.log('redis连接超时'); | ||
175 | - return; | ||
176 | - } | ||
177 | - if (options.attempt > 10) { | ||
178 | - return 1000 * 60 * 60 * 0.5; | ||
179 | - } | ||
180 | - return Math.min(options.attempt * 100, 1000); | ||
181 | - } | ||
182 | - } | 96 | + useCache: true |
183 | }); | 97 | }); |
184 | } else if (isTest) { | 98 | } else if (isTest) { |
185 | Object.assign(module.exports, { | 99 | Object.assign(module.exports, { |
@@ -192,8 +106,6 @@ if (isProduction) { | @@ -192,8 +106,6 @@ if (isProduction) { | ||
192 | store: process.env.TEST_STORE || 'http://192.168.102.210:8080/portal-gateway/', | 106 | store: process.env.TEST_STORE || 'http://192.168.102.210:8080/portal-gateway/', |
193 | liveApi: process.env.TEST_LIVE || 'http://testapi.live.yohops.com:9999/', | 107 | liveApi: process.env.TEST_LIVE || 'http://testapi.live.yohops.com:9999/', |
194 | singleApi: process.env.TEST_SINGLE || 'http://api-test1.yohops.com:9999/', | 108 | singleApi: process.env.TEST_SINGLE || 'http://api-test1.yohops.com:9999/', |
195 | - imSocket: process.env.TEST_IM_SOCKET || 'ws://socket.yohobuy.com:10240', | ||
196 | - imCs: process.env.TEST_IM_CS || 'http://im.yohobuy.com/api', | ||
197 | platformApi: 'http://192.168.102.48:8088/' | 109 | platformApi: 'http://192.168.102.48:8088/' |
198 | }, | 110 | }, |
199 | memcache: { | 111 | memcache: { |
@@ -204,26 +116,6 @@ if (isProduction) { | @@ -204,26 +116,6 @@ if (isProduction) { | ||
204 | reconnect: 5000, | 116 | reconnect: 5000, |
205 | retries: 0 | 117 | retries: 0 |
206 | }, | 118 | }, |
207 | - useCache: true, | ||
208 | - alipayConfig: { | ||
209 | - payUrl: 'https://mapi.alipay.com/gateway.do', | ||
210 | - service: 'alipay.wap.create.direct.pay.by.user', | ||
211 | - partner: '2088701661478015', | ||
212 | - inputCharset: 'utf-8', | ||
213 | - notifyUrl: (process.env.TEST_SERVICE || 'http://service-test1.yohops.com:9999/') + 'payment/alipay_notify', | ||
214 | - returnUrl: '/shopping/pay/aliwapreturn', | ||
215 | - signType: 'MD5', | ||
216 | - paymentType: '1', | ||
217 | - alipayKey: 'kcxawi9bb07mzh0aq2wcirsf9znusobw', | ||
218 | - sellerMail: 'zfb@yoho.cn', | ||
219 | - merchantUrl: 'http://m.yohobuy.com/home/orderDetail?order_code=' | ||
220 | - }, | ||
221 | - WxPayConfig: { | ||
222 | - appId: 'wx75e5a7c0c88e45c2', | ||
223 | - mchId: '1227694201', | ||
224 | - key: '7e6f3307b64cc87c79c472814b88f7fb', | ||
225 | - appSecret: 'ce21ae4a3f93852279175a167e54509b', | ||
226 | - notifyUrl: (process.env.TEST_SERVICE || 'http://service-test1.yohops.com:9999/') + 'payment/weixin_notify', | ||
227 | - } | 119 | + useCache: true |
228 | }); | 120 | }); |
229 | } | 121 | } |
-
Please register or login to post a comment