Compare commits

...

6 Commits

Author SHA1 Message Date
xiaojunnuo
a096a43c56 v1.1.5 2023-07-03 17:59:34 +08:00
xiaojunnuo
8114a33d20 build: prepare to build 2023-07-03 17:57:54 +08:00
xiaojunnuo
9f3adddd41 refactor: cacheControl 2023-07-03 17:57:26 +08:00
xiaojunnuo
05f74ab654 refactor: cacheControl 2023-07-03 17:43:21 +08:00
xiaojunnuo
0317118cd9 refactor: 1.1.4 2023-07-03 13:42:48 +08:00
xiaojunnuo
461de8d269 refactor: 1.1.4 2023-07-03 12:39:03 +08:00
28 changed files with 119 additions and 68 deletions

View File

@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.5](https://github.com/certd/certd/compare/v1.1.4...v1.1.5) (2023-07-03)
**Note:** Version bump only for package root
## [1.1.4](https://github.com/certd/certd/compare/v1.1.3...v1.1.4) (2023-07-03)
### Bug Fixes

View File

@@ -9,5 +9,5 @@
}
},
"npmClient": "pnpm",
"version": "1.1.4"
"version": "1.1.5"
}

View File

@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.5](https://github.com/publishlab/node-acme-client/compare/v1.1.4...v1.1.5) (2023-07-03)
**Note:** Version bump only for package @certd/acme-client
## [1.1.4](https://github.com/publishlab/node-acme-client/compare/v1.1.3...v1.1.4) (2023-07-03)
**Note:** Version bump only for package @certd/acme-client

View File

@@ -1 +1 @@
12:25
17:57

View File

@@ -3,7 +3,7 @@
"description": "Simple and unopinionated ACME client",
"private": false,
"author": "nmorsman",
"version": "1.1.4",
"version": "1.1.5",
"main": "src/index.js",
"types": "types",
"license": "MIT",
@@ -58,5 +58,5 @@
"bugs": {
"url": "https://github.com/publishlab/node-acme-client/issues"
},
"gitHead": "ecfcada8020661b922cbe4f4984d76efb7f2b3e3"
"gitHead": "b258e926209fef4cc4d633b0383eb54e26c516f9"
}

View File

@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.5](https://github.com/certd/certd/compare/v1.1.4...v1.1.5) (2023-07-03)
**Note:** Version bump only for package @certd/pipeline
## [1.1.4](https://github.com/certd/certd/compare/v1.1.3...v1.1.4) (2023-07-03)
### Performance Improvements

View File

@@ -1,7 +1,7 @@
{
"name": "@certd/pipeline",
"private": false,
"version": "1.1.4",
"version": "1.1.5",
"main": "./src/index.ts",
"module": "./src/index.ts",
"types": "./src/index.ts",
@@ -23,7 +23,7 @@
"qs": "^6.11.2"
},
"devDependencies": {
"@certd/acme-client": "^1.1.4",
"@certd/acme-client": "^1.1.5",
"@rollup/plugin-commonjs": "^23.0.4",
"@rollup/plugin-json": "^6.0.0",
"@rollup/plugin-node-resolve": "^15.0.1",
@@ -56,5 +56,5 @@
"vite": "^4.3.8",
"vue-tsc": "^1.6.5"
},
"gitHead": "ecfcada8020661b922cbe4f4984d76efb7f2b3e3"
"gitHead": "b258e926209fef4cc4d633b0383eb54e26c516f9"
}

View File

@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.5](https://github.com/certd/certd/compare/v1.1.4...v1.1.5) (2023-07-03)
**Note:** Version bump only for package @certd/plugin-aliyun
## [1.1.4](https://github.com/certd/certd/compare/v1.1.3...v1.1.4) (2023-07-03)
### Performance Improvements

View File

@@ -1,7 +1,7 @@
{
"name": "@certd/plugin-aliyun",
"private": false,
"version": "1.1.4",
"version": "1.1.5",
"main": "./src/index.ts",
"module": "./src/index.ts",
"types": "./src/index.ts",
@@ -23,10 +23,10 @@
"node-forge": "^0.10.0"
},
"devDependencies": {
"@certd/acme-client": "^1.1.4",
"@certd/pipeline": "^1.1.4",
"@certd/plugin-cert": "^1.1.4",
"@certd/plugin-util": "^1.1.4",
"@certd/acme-client": "^1.1.5",
"@certd/pipeline": "^1.1.5",
"@certd/plugin-cert": "^1.1.5",
"@certd/plugin-util": "^1.1.5",
"@midwayjs/core": "^3.0.0",
"@midwayjs/decorator": "^3.0.0",
"@rollup/plugin-commonjs": "^23.0.4",
@@ -59,5 +59,5 @@
"vite": "^3.1.0",
"vue-tsc": "^0.38.9"
},
"gitHead": "ecfcada8020661b922cbe4f4984d76efb7f2b3e3"
"gitHead": "b258e926209fef4cc4d633b0383eb54e26c516f9"
}

View File

@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.5](https://github.com/certd/certd/compare/v1.1.4...v1.1.5) (2023-07-03)
**Note:** Version bump only for package @certd/plugin-all
## [1.1.4](https://github.com/certd/certd/compare/v1.1.3...v1.1.4) (2023-07-03)
### Performance Improvements

View File

@@ -1,7 +1,7 @@
{
"name": "@certd/plugin-all",
"private": false,
"version": "1.1.4",
"version": "1.1.5",
"main": "./src/index.ts",
"module": "./src/index.ts",
"types": "./src/index.ts",
@@ -17,12 +17,12 @@
"preview": "vite preview"
},
"devDependencies": {
"@certd/pipeline": "^1.1.4",
"@certd/plugin-aliyun": "^1.1.4",
"@certd/plugin-cert": "^1.1.4",
"@certd/plugin-host": "^1.1.4",
"@certd/plugin-huawei": "^1.1.4",
"@certd/plugin-tencent": "^1.1.4",
"@certd/pipeline": "^1.1.5",
"@certd/plugin-aliyun": "^1.1.5",
"@certd/plugin-cert": "^1.1.5",
"@certd/plugin-host": "^1.1.5",
"@certd/plugin-huawei": "^1.1.5",
"@certd/plugin-tencent": "^1.1.5",
"@rollup/plugin-commonjs": "^23.0.4",
"@rollup/plugin-json": "^6.0.0",
"@rollup/plugin-node-resolve": "^15.0.1",
@@ -48,5 +48,5 @@
"vite": "^3.1.0",
"vue-tsc": "^0.38.9"
},
"gitHead": "ecfcada8020661b922cbe4f4984d76efb7f2b3e3"
"gitHead": "b258e926209fef4cc4d633b0383eb54e26c516f9"
}

View File

@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.5](https://github.com/certd/certd/compare/v1.1.4...v1.1.5) (2023-07-03)
**Note:** Version bump only for package @certd/plugin-cert
## [1.1.4](https://github.com/certd/certd/compare/v1.1.3...v1.1.4) (2023-07-03)
### Performance Improvements

View File

@@ -1,7 +1,7 @@
{
"name": "@certd/plugin-cert",
"private": false,
"version": "1.1.4",
"version": "1.1.5",
"main": "./src/index.ts",
"module": "./src/index.ts",
"types": "./src/index.ts",
@@ -17,8 +17,8 @@
"preview": "vite preview"
},
"dependencies": {
"@certd/acme-client": "^1.1.4",
"@certd/pipeline": "^1.1.4",
"@certd/acme-client": "^1.1.5",
"@certd/pipeline": "^1.1.5",
"jszip": "^3.10.1",
"node-forge": "^0.10.0"
},
@@ -57,5 +57,5 @@
"vite": "^3.1.0",
"vue-tsc": "^0.38.9"
},
"gitHead": "ecfcada8020661b922cbe4f4984d76efb7f2b3e3"
"gitHead": "b258e926209fef4cc4d633b0383eb54e26c516f9"
}

View File

@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.5](https://github.com/certd/certd/compare/v1.1.4...v1.1.5) (2023-07-03)
**Note:** Version bump only for package @certd/plugin-host
## [1.1.4](https://github.com/certd/certd/compare/v1.1.3...v1.1.4) (2023-07-03)
### Performance Improvements

View File

@@ -1,7 +1,7 @@
{
"name": "@certd/plugin-host",
"private": false,
"version": "1.1.4",
"version": "1.1.5",
"main": "./src/index.ts",
"module": "./src/index.ts",
"types": "./src/index.ts",
@@ -17,8 +17,8 @@
"preview": "vite preview"
},
"dependencies": {
"@certd/pipeline": "^1.1.4",
"@certd/plugin-cert": "^1.1.4",
"@certd/pipeline": "^1.1.5",
"@certd/plugin-cert": "^1.1.5",
"ssh2": "^0.8.9"
},
"devDependencies": {
@@ -57,5 +57,5 @@
"vite": "^3.1.0",
"vue-tsc": "^0.38.9"
},
"gitHead": "ecfcada8020661b922cbe4f4984d76efb7f2b3e3"
"gitHead": "b258e926209fef4cc4d633b0383eb54e26c516f9"
}

View File

@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.5](https://github.com/certd/certd/compare/v1.1.4...v1.1.5) (2023-07-03)
**Note:** Version bump only for package @certd/plugin-huawei
## [1.1.4](https://github.com/certd/certd/compare/v1.1.3...v1.1.4) (2023-07-03)
### Performance Improvements

View File

@@ -1,7 +1,7 @@
{
"name": "@certd/plugin-huawei",
"private": false,
"version": "1.1.4",
"version": "1.1.5",
"main": "./src/index.ts",
"module": "./src/index.ts",
"types": "./src/index.ts",
@@ -17,10 +17,10 @@
"preview": "vite preview"
},
"dependencies": {
"@certd/acme-client": "^1.1.4",
"@certd/pipeline": "^1.1.4",
"@certd/plugin-cert": "^1.1.4",
"@certd/plugin-util": "^1.1.4",
"@certd/acme-client": "^1.1.5",
"@certd/pipeline": "^1.1.5",
"@certd/plugin-cert": "^1.1.5",
"@certd/plugin-util": "^1.1.5",
"axios": "^0.27.2",
"dayjs": "^1.11.6",
"lodash": "^4.17.21",
@@ -59,5 +59,5 @@
"vite": "^3.1.0",
"vue-tsc": "^0.38.9"
},
"gitHead": "ecfcada8020661b922cbe4f4984d76efb7f2b3e3"
"gitHead": "b258e926209fef4cc4d633b0383eb54e26c516f9"
}

View File

@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.5](https://github.com/certd/certd/compare/v1.1.4...v1.1.5) (2023-07-03)
**Note:** Version bump only for package @certd/plugin-tencent
## [1.1.4](https://github.com/certd/certd/compare/v1.1.3...v1.1.4) (2023-07-03)
### Performance Improvements

View File

@@ -1,7 +1,7 @@
{
"name": "@certd/plugin-tencent",
"private": false,
"version": "1.1.4",
"version": "1.1.5",
"main": "./src/index.ts",
"module": "./src/index.ts",
"types": "./src/index.ts",
@@ -17,9 +17,9 @@
"preview": "vite preview"
},
"dependencies": {
"@certd/pipeline": "^1.1.4",
"@certd/plugin-cert": "^1.1.4",
"@certd/plugin-util": "^1.1.4",
"@certd/pipeline": "^1.1.5",
"@certd/plugin-cert": "^1.1.5",
"@certd/plugin-util": "^1.1.5",
"tencentcloud-sdk-nodejs": "^4.0.44"
},
"devDependencies": {
@@ -58,5 +58,5 @@
"vite": "^3.1.0",
"vue-tsc": "^0.38.9"
},
"gitHead": "ecfcada8020661b922cbe4f4984d76efb7f2b3e3"
"gitHead": "b258e926209fef4cc4d633b0383eb54e26c516f9"
}

View File

@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.5](https://github.com/certd/certd/compare/v1.1.4...v1.1.5) (2023-07-03)
**Note:** Version bump only for package @certd/plugin-util
## [1.1.4](https://github.com/certd/certd/compare/v1.1.3...v1.1.4) (2023-07-03)
### Performance Improvements

View File

@@ -1,7 +1,7 @@
{
"name": "@certd/plugin-util",
"private": false,
"version": "1.1.4",
"version": "1.1.5",
"main": "./src/index.ts",
"module": "./src/index.ts",
"types": "./src/index.ts",
@@ -21,7 +21,7 @@
"shelljs": "^0.8.5"
},
"devDependencies": {
"@certd/pipeline": "^1.1.4",
"@certd/pipeline": "^1.1.5",
"@rollup/plugin-commonjs": "^23.0.4",
"@rollup/plugin-json": "^6.0.0",
"@rollup/plugin-node-resolve": "^15.0.1",
@@ -44,5 +44,5 @@
"vite": "^3.1.0",
"vue-tsc": "^0.38.9"
},
"gitHead": "ecfcada8020661b922cbe4f4984d76efb7f2b3e3"
"gitHead": "b258e926209fef4cc4d633b0383eb54e26c516f9"
}

View File

@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.5](https://github.com/certd/certd/compare/v1.1.4...v1.1.5) (2023-07-03)
**Note:** Version bump only for package @certd/ui-client
## [1.1.4](https://github.com/certd/certd/compare/v1.1.3...v1.1.4) (2023-07-03)
### Bug Fixes

View File

@@ -1,6 +1,6 @@
{
"name": "@certd/ui-client",
"version": "1.1.4",
"version": "1.1.5",
"private": true,
"scripts": {
"dev": "vite",
@@ -22,7 +22,7 @@
"dependencies": {
"@ant-design/colors": "^6.0.0",
"@ant-design/icons-vue": "^6.0.1",
"@certd/acme-client": "^1.1.4",
"@certd/acme-client": "^1.1.5",
"@fast-crud/fast-crud": "^1.14.4",
"@fast-crud/fast-extends": "^1.14.4",
"@fast-crud/ui-antdv": "^1.14.4",
@@ -59,7 +59,7 @@
"vuedraggable": "^4.0.1"
},
"devDependencies": {
"@certd/pipeline": "^1.1.4",
"@certd/pipeline": "^1.1.5",
"@rollup/plugin-commonjs": "^23.0.4",
"@rollup/plugin-node-resolve": "^15.0.1",
"@types/chai": "^4.3.4",

View File

@@ -3,6 +3,10 @@
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
## [1.1.5](https://github.com/fast-crud/fast-server-js/compare/v1.1.4...v1.1.5) (2023-07-03)
**Note:** Version bump only for package @certd/ui-server
## [1.1.4](https://github.com/fast-crud/fast-server-js/compare/v1.1.3...v1.1.4) (2023-07-03)
### Performance Improvements

View File

@@ -1,6 +1,6 @@
{
"name": "@certd/ui-server",
"version": "1.1.4",
"version": "1.1.5",
"description": "fast-server base midway",
"private": true,
"scripts": {
@@ -21,15 +21,15 @@
"mig": "typeorm migration:create -n name"
},
"dependencies": {
"@certd/acme-client": "^1.1.4",
"@certd/pipeline": "^1.1.4",
"@certd/plugin-aliyun": "^1.1.4",
"@certd/plugin-all": "^1.1.4",
"@certd/plugin-cert": "^1.1.4",
"@certd/plugin-host": "^1.1.4",
"@certd/plugin-huawei": "^1.1.4",
"@certd/plugin-tencent": "^1.1.4",
"@certd/plugin-util": "^1.1.4",
"@certd/acme-client": "^1.1.5",
"@certd/pipeline": "^1.1.5",
"@certd/plugin-aliyun": "^1.1.5",
"@certd/plugin-all": "^1.1.5",
"@certd/plugin-cert": "^1.1.5",
"@certd/plugin-host": "^1.1.5",
"@certd/plugin-huawei": "^1.1.5",
"@certd/plugin-tencent": "^1.1.5",
"@certd/plugin-util": "^1.1.5",
"@koa/cors": "^3.4.3",
"@midwayjs/bootstrap": "^3.9.1",
"@midwayjs/cache": "^3.9.0",

View File

@@ -16,7 +16,7 @@ const development = {
staticFile: {
usePrecompiledGzip: true,
buffer: true,
maxAge: 60 * 60 * 24 * 30 * 1000,
maxAge: 30 * 24 * 60 * 60 * 1000,
gzip: true,
dirs: {
default: {
@@ -25,11 +25,6 @@ const development = {
alias: {
'/': '/index.html',
},
files: {
'/index.html': {
maxAge: 60 * 60 * 1000,
},
},
},
},
},

View File

@@ -4,7 +4,7 @@ import _ from 'lodash';
const yaml = require('js-yaml');
const fs = require('fs');
function parseEnv() {
function parseEnv(defaultConfig: any) {
const config = {};
for (const key in process.env) {
let keyName = key;
@@ -13,21 +13,30 @@ function parseEnv() {
}
keyName = keyName.replace('certd_', '');
const configKey = keyName.replace('_', '.');
_.set(config, configKey, process.env[key]);
const oldValue = _.get(defaultConfig, configKey);
let value: any = process.env[key];
if (typeof oldValue === 'boolean') {
value = value === 'true';
} else if (Number.isInteger(oldValue)) {
value = parseInt(value, 10);
} else if (typeof oldValue === 'number') {
value = parseFloat(value);
}
_.set(config, configKey, value);
}
return config;
}
export function load(env = '') {
export function load(config, env = '') {
// Get document, or throw exception on error
const yamlPath = path.join(process.cwd(), `.env.${env}.yaml`);
const doc = yaml.load(fs.readFileSync(yamlPath, 'utf8'));
_.merge(doc, parseEnv());
_.merge(doc, parseEnv(config));
return doc;
}
export function mergeConfig(config: any, envType: string) {
_.merge(config, load(envType));
_.merge(config, load(config, envType));
const keys = _.get(config, 'auth.jwt.secret');
if (keys) {
config.keys = keys;

View File

@@ -16,7 +16,6 @@ import { AuthorityMiddleware } from './middleware/authority';
import * as staticFile from '@midwayjs/static-file';
import * as cron from './plugins/cron';
import { logger } from './utils/logger';
@Configuration({
imports: [koa, orm, cache, flyway, validateComp, cron, staticFile],
importConfigs: [