1
0
Fork 0
mirror of synced 2024-12-19 12:41:10 -05:00

node 16.13

This commit is contained in:
Vitaliy Snurnitsin 2022-01-10 01:56:10 +03:00
parent d3b5a77efb
commit f180a9cc5a
7 changed files with 11824 additions and 5467 deletions

View file

@ -1,4 +1,4 @@
FROM node:14.2-alpine3.11 AS frontend-builder FROM node:16.13.0-alpine3.12 AS frontend-builder
COPY frontend/ /app COPY frontend/ /app
RUN cd /app && npm install && npm run build RUN cd /app && npm install && npm run build

View file

@ -1,6 +1,6 @@
#!/bin/bash #!/bin/bash
image="node:14.2-alpine3.11" image="node:16.13.0-alpine3.12"
uid="$(id -u $USER)" uid="$(id -u $USER)"
docker run -u $uid -w /app -v $(pwd):/app $image npm i && \ docker run -u $uid -w /app -v $(pwd):/app $image npm i && \

17120
frontend/package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -7,16 +7,16 @@
"private": true, "private": true,
"scripts": { "scripts": {
"dev": "cross-env NODE_ENV=development webpack-dev-server --hot", "dev": "cross-env NODE_ENV=development webpack-dev-server --hot",
"build": "cross-env NODE_ENV=production webpack --progress --hide-modules" "build": "cross-env NODE_ENV=production webpack --progress"
}, },
"dependencies": { "dependencies": {
"axios": "^0.19.2", "axios": "^0.24.0",
"bootstrap-vue": "^2.21.2", "bootstrap-vue": "^2.21.2",
"normalize.css": "^8.0.1", "normalize.css": "^8.0.1",
"vue": "^2.6.12", "vue": "^2.6.14",
"vue-clipboard2": "^0.2.1", "vue-clipboard2": "^0.3.3",
"vue-cookies": "^1.7.4", "vue-cookies": "^1.7.4",
"vue-good-table": "^2.21.1", "vue-good-table": "^2.21.11",
"vue-notification": "^1.3.20" "vue-notification": "^1.3.20"
}, },
"browserslist": [ "browserslist": [
@ -25,23 +25,23 @@
"not ie <= 8" "not ie <= 8"
], ],
"devDependencies": { "devDependencies": {
"@babel/core": "^7.8.6", "@babel/core": "^7.16.5",
"@babel/plugin-proposal-class-properties": "^7.0.0", "@babel/plugin-proposal-class-properties": "^7.16.7",
"@babel/plugin-proposal-json-strings": "^7.0.0", "@babel/plugin-proposal-json-strings": "^7.16.7",
"@babel/plugin-syntax-dynamic-import": "^7.0.0", "@babel/plugin-syntax-dynamic-import": "^7.8.3",
"@babel/plugin-syntax-import-meta": "^7.0.0", "@babel/plugin-syntax-import-meta": "^7.10.4",
"@babel/preset-env": "^7.0.0", "@babel/preset-env": "^7.16.5",
"babel-loader": "^8.0.0", "babel-loader": "^8.2.3",
"cross-env": "^7.0.0", "cross-env": "^7.0.3",
"css-loader": "^3.4.2", "css-loader": "^6.5.1",
"file-loader": "^5.1.0", "file-loader": "^6.2.0",
"node-sass": "^4.13.1", "node-sass": "^7.0.1",
"sass-loader": "^8.0.2", "sass-loader": "^12.4.0",
"terser-webpack-plugin": "^2.3.5", "terser-webpack-plugin": "^5.3.0",
"vue-loader": "^15.9.0", "vue-loader": "^15.9.8",
"vue-template-compiler": "^2.6.11", "vue-template-compiler": "^2.6.14",
"webpack": "^4.42.0", "webpack": "^5.65.0",
"webpack-cli": "^3.3.11", "webpack-cli": "^4.9.1",
"webpack-dev-server": "^3.10.3" "webpack-dev-server": "^4.7.2"
} }
} }

View file

@ -1,70 +1,55 @@
var path = require('path') // Generated using webpack-cli https://github.com/webpack/webpack-cli
var webpack = require('webpack')
const TerserPlugin = require('terser-webpack-plugin');
module.exports = { const path = require('path');
mode: 'production',
entry: { const isProduction = process.env.NODE_ENV == 'production';
bundle: [
'./src/main.js',
], const config = {
style: [ entry: {
'./src/style.js', bundle: [
] './src/main.js',
},
output: {
path: path.resolve(__dirname, './static/dist'),
publicPath: '/dist/',
filename: '[name].min.js'
},
module: {
rules: [
{
test: /\.css$/,
use: [
'vue-style-loader',
'css-loader'
], ],
}, style: [
'./src/style.js',
{ ]
test: /\.js$/,
loader: 'babel-loader',
exclude: /node_modules/
}
]
},
resolve: {
alias: {
'vue$': 'vue/dist/vue.esm.js'
}, },
extensions: ['*', '.js', '.vue', '.json'] output: {
}, path: path.resolve(__dirname, './static/dist'),
devServer: { publicPath: '/dist/',
historyApiFallback: true, filename: '[name].min.js'
noInfo: true, },
overlay: true plugins: [
}, ],
performance: { module: {
hints: false rules: [
}, {
} test: /\.css$/,
use: [
'vue-style-loader',
'css-loader'
],
},
{
test: /\.js$/,
exclude: /node_modules/,
loader: 'babel-loader',
options: {
presets: ['@babel/preset-env']
}
},
],
},
resolve: {
alias: {
'vue$': 'vue/dist/vue.esm.js'
},
extensions: ['*', '.js', '.vue', '.json']
},
};
if (process.env.NODE_ENV === 'production') { module.exports = () => {
module.exports.devtool = 'false' config.mode = 'production';
// http://vue-loader.vuejs.org/en/workflow/production.html
module.exports.plugins = (module.exports.plugins || []).concat([ return config;
new webpack.DefinePlugin({ };
'process.env': {
NODE_ENV: '"production"'
}
}),
new TerserPlugin({
sourceMap: false
}),
new webpack.LoaderOptionsPlugin({
minimize: true
})
])
}

View file

@ -4,7 +4,7 @@ apt-get update
apt-get install -y curl apt-get install -y curl
apt-get install -y libc6 libc6-dev gcc-arm-linux-gnueabi gcc-aarch64-linux-gnu apt-get install -y libc6 libc6-dev gcc-arm-linux-gnueabi gcc-aarch64-linux-gnu
curl -sL https://deb.nodesource.com/setup_14.x | bash - curl -sL https://deb.nodesource.com/setup_16.x | bash -
apt-get install -y nodejs apt-get install -y nodejs
PATH=$PATH:~/go/bin PATH=$PATH:~/go/bin

View file

@ -4,7 +4,7 @@ apt-get update
apt-get install -y curl apt-get install -y curl
apt-get install -y libc6 libc6-dev libc6-dev-i386 apt-get install -y libc6 libc6-dev libc6-dev-i386
curl -sL https://deb.nodesource.com/setup_14.x | bash - curl -sL https://deb.nodesource.com/setup_16.x | bash -
apt-get install -y nodejs apt-get install -y nodejs
PATH=$PATH:~/go/bin PATH=$PATH:~/go/bin