Commit 8214eee1 authored by 朱松文's avatar 朱松文

add env files

parent 1802d049
NODE_ENV = development
VUE_APP_MY_ENV = dev
\ No newline at end of file
NODE_ENV = production
VUE_APP_MY_ENV = prod
\ No newline at end of file
NODE_ENV = production
VUE_APP_MY_ENV = stage
\ No newline at end of file
......@@ -3,8 +3,9 @@
"version": "0.1.0",
"private": true,
"scripts": {
"serve": "vue-cli-service serve",
"build": "vue-cli-service build",
"serve": "vue-cli-service serve --mode dev",
"stage": "vue-cli-service build --mode stage",
"prod": "vue-cli-service build --mode prod",
"lint": "vue-cli-service lint"
},
"dependencies": {
......
......@@ -2,12 +2,15 @@
//测试服务器:10.2.70.19
const API = {
'development': {
'dev': {
skyNet: 'http://10.2.70.19:48021/'
},
'production': {
'stage': {
skyNet: 'http://10.2.70.19:48021/'
},
'prod': {
skyNet: 'http://10.2.70.19:48021/'
}
}
export default API[process.env.NODE_ENV]
\ No newline at end of file
export default API[process.env.VUE_APP_MY_ENV]
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment