fix docker build
This commit is contained in:
@@ -3,8 +3,10 @@ FROM node:10
|
|||||||
|
|
||||||
WORKDIR /usr/src/app
|
WORKDIR /usr/src/app
|
||||||
|
|
||||||
|
|
||||||
COPY package.json .
|
COPY package.json .
|
||||||
COPY pm2.json .
|
COPY pm2.json .
|
||||||
|
COPY .env.production .
|
||||||
|
|
||||||
# install backend dependencies
|
# install backend dependencies
|
||||||
RUN yarn
|
RUN yarn
|
||||||
@@ -22,7 +24,7 @@ WORKDIR /usr/src/app/client
|
|||||||
RUN yarn
|
RUN yarn
|
||||||
|
|
||||||
# build frontend
|
# build frontend
|
||||||
RUN yarn build
|
RUN export $(cat /usr/src/app/.env.production); yarn build
|
||||||
|
|
||||||
WORKDIR /usr/src/app
|
WORKDIR /usr/src/app
|
||||||
|
|
||||||
|
|||||||
@@ -8,7 +8,7 @@ module.exports = {
|
|||||||
publicPath: process.env.BASE_URL,
|
publicPath: process.env.BASE_URL,
|
||||||
configureWebpack: {
|
configureWebpack: {
|
||||||
plugins: [
|
plugins: [
|
||||||
new webpack.NormalModuleReplacementPlugin(/element-ui[\/\\]lib[\/\\]locale[\/\\]lang[\/\\]zh-CN/, 'element-ui/lib/locale/lang/en')
|
new webpack.NormalModuleReplacementPlugin(/element-ui[/\\]lib[/\\]locale[/\\]lang[/\\]zh-CN/, 'element-ui/lib/locale/lang/en')
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
devServer: {
|
devServer: {
|
||||||
@@ -16,6 +16,6 @@ module.exports = {
|
|||||||
},
|
},
|
||||||
transpileDependencies: [
|
transpileDependencies: [
|
||||||
/\bvue-awesome\b/,
|
/\bvue-awesome\b/,
|
||||||
'vuex-persist',
|
'vuex-persist'
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user