|
|
-
- import Vue from 'vue'
- import api from '@/api/api.js'
- import utils from './utils/utils.js'
-
-
- // 当前环境
- const type = 'prod'
-
-
- // 环境配置
- const config = {
- dev : {
- // baseUrl : 'http://8.138.162.67:8000/a-notice-api',
- baseUrl : 'http://h5.xzaiyp.top/a-notice-api',
- },
- test2 : {
- baseUrl : 'http://test-lzx.natapp1.cc/a-notice-api',
- },
- test : {
- baseUrl : 'https://admin.anqi.shop/a-notice-api',
- },
- prod : {//正式环境
- baseUrl : 'https://admin.ytonggao.com/a-notice-api',
- }
- }
-
-
- // 默认配置
- const defaultConfig = {
- mapKey : '',
- // aliOss : {
- // url : 'https://tennis-oss.xzaiyp.top/',
- // config : {
- // //桶的地址
- // region: 'oss-cn-guangzhou',
- // //id
- // accessKeyId:'LTAI5tNycA46YTwm383dRvMV',
- // //密钥
- // accessKeySecret:'tAdbYQCmdur6jbZ8hjvgB7T1Z52mIG',
- // //桶的名字
- // bucket: 'zhuoqiu-image',
- // endpoint:'oss-cn-guangzhou.aliyuncs.com',
- // }
- // },
- aliOss : {
- url : 'https://image.ytonggao.com/',
- config : {
- //桶的地址
- region: 'oss-cn-chengdu',
- //id
- accessKeyId:'LTAI5t9Hw5DTgahn82upXu4L',
- //密钥
- accessKeySecret:'hGJPlLmwK9RVH3FQHkXWCSPgPiGrHj',
- //桶的名字
- bucket: 'zkcm',
- endpoint:'oss-cn-chengdu.aliyuncs.com',
- }
- },
- }
- // oss:
- // accessKey: LTAI5t9Hw5DTgahn82upXu4L
- // secretKey: hGJPlLmwK9RVH3FQHkXWCSPgPiGrHj
- // endpoint: oss-cn-chengdu.aliyuncs.com
- // bucketName: zkcm
- // staticDomain:
-
-
- Vue.prototype.$config = utils.deepMergeObject(defaultConfig, config[type])
-
- Vue.prototype.$api = api
-
- export default Vue.prototype.$config
|