Compare commits
No commits in common. "feat-configuration-center" and "master" have entirely different histories.
feat-confi
...
master
1
.gitignore
vendored
1
.gitignore
vendored
@ -35,4 +35,3 @@ lerna-debug.log*
|
|||||||
|
|
||||||
/config.yml
|
/config.yml
|
||||||
tsconfig.build.tsbuildinfo
|
tsconfig.build.tsbuildinfo
|
||||||
.eslintcache
|
|
||||||
|
1
.husky/.gitignore
vendored
1
.husky/.gitignore
vendored
@ -1 +0,0 @@
|
|||||||
_
|
|
@ -1,5 +0,0 @@
|
|||||||
#!/bin/sh
|
|
||||||
. "$(dirname "$0")/_/husky.sh"
|
|
||||||
|
|
||||||
npx lint-staged
|
|
||||||
npm test
|
|
670
package-lock.json
generated
670
package-lock.json
generated
@ -24,7 +24,6 @@
|
|||||||
"body-parser": "^1.19.0",
|
"body-parser": "^1.19.0",
|
||||||
"class-transformer": "^0.3.2",
|
"class-transformer": "^0.3.2",
|
||||||
"class-validator": "^0.13.1",
|
"class-validator": "^0.13.1",
|
||||||
"configuration": "file:../configuration",
|
|
||||||
"debug": "^4.3.1",
|
"debug": "^4.3.1",
|
||||||
"graphql": "^15.5.0",
|
"graphql": "^15.5.0",
|
||||||
"graphql-tools": "^8.1.0",
|
"graphql-tools": "^8.1.0",
|
||||||
@ -63,9 +62,7 @@
|
|||||||
"eslint": "^7.12.1",
|
"eslint": "^7.12.1",
|
||||||
"eslint-config-prettier": "7.2.0",
|
"eslint-config-prettier": "7.2.0",
|
||||||
"eslint-plugin-prettier": "^3.1.4",
|
"eslint-plugin-prettier": "^3.1.4",
|
||||||
"husky": "^7.0.2",
|
|
||||||
"jest": "^26.6.3",
|
"jest": "^26.6.3",
|
||||||
"lint-staged": "^11.1.2",
|
|
||||||
"prettier": "^2.1.2",
|
"prettier": "^2.1.2",
|
||||||
"supertest": "^6.0.0",
|
"supertest": "^6.0.0",
|
||||||
"ts-jest": "^26.4.3",
|
"ts-jest": "^26.4.3",
|
||||||
@ -75,24 +72,6 @@
|
|||||||
"typescript": "^4.0.5"
|
"typescript": "^4.0.5"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"../configuration": {
|
|
||||||
"version": "0.0.1",
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"debug": "^4.3.2",
|
|
||||||
"etcd3": "^1.1.0",
|
|
||||||
"js-yaml": "^4.1.0"
|
|
||||||
},
|
|
||||||
"devDependencies": {
|
|
||||||
"@tsconfig/node14": "^1.0.1",
|
|
||||||
"@types/debug": "^4.1.7",
|
|
||||||
"@types/js-yaml": "^4.0.3",
|
|
||||||
"@types/node": "^14.17.17",
|
|
||||||
"rimraf": "^3.0.2",
|
|
||||||
"ts-node": "^10.2.1",
|
|
||||||
"typescript": "^4.4.4"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/@angular-devkit/core": {
|
"node_modules/@angular-devkit/core": {
|
||||||
"version": "11.2.6",
|
"version": "11.2.6",
|
||||||
"resolved": "https://npm.ivanli.cc/@angular-devkit%2fcore/-/core-11.2.6.tgz",
|
"resolved": "https://npm.ivanli.cc/@angular-devkit%2fcore/-/core-11.2.6.tgz",
|
||||||
@ -4302,8 +4281,8 @@
|
|||||||
"version": "3.1.0",
|
"version": "3.1.0",
|
||||||
"resolved": "https://npm.ivanli.cc/aggregate-error/-/aggregate-error-3.1.0.tgz",
|
"resolved": "https://npm.ivanli.cc/aggregate-error/-/aggregate-error-3.1.0.tgz",
|
||||||
"integrity": "sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==",
|
"integrity": "sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==",
|
||||||
"devOptional": true,
|
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
|
"optional": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"clean-stack": "^2.0.0",
|
"clean-stack": "^2.0.0",
|
||||||
"indent-string": "^4.0.0"
|
"indent-string": "^4.0.0"
|
||||||
@ -6092,8 +6071,8 @@
|
|||||||
"version": "2.2.0",
|
"version": "2.2.0",
|
||||||
"resolved": "https://npm.ivanli.cc/clean-stack/-/clean-stack-2.2.0.tgz",
|
"resolved": "https://npm.ivanli.cc/clean-stack/-/clean-stack-2.2.0.tgz",
|
||||||
"integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==",
|
"integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==",
|
||||||
"devOptional": true,
|
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
|
"optional": true,
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=6"
|
"node": ">=6"
|
||||||
}
|
}
|
||||||
@ -6273,63 +6252,6 @@
|
|||||||
"node": ">=8.10.0"
|
"node": ">=8.10.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/cli-truncate": {
|
|
||||||
"version": "2.1.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/cli-truncate/-/cli-truncate-2.1.0.tgz",
|
|
||||||
"integrity": "sha512-n8fOixwDD6b/ObinzTrp1ZKFzbgvKZvuz/TvejnLn1aQfC6r52XEx85FmuC+3HI+JM7coBRXUvNqEU2PHVrHpg==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"slice-ansi": "^3.0.0",
|
|
||||||
"string-width": "^4.2.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"url": "https://github.com/sponsors/sindresorhus"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/cli-truncate/node_modules/is-fullwidth-code-point": {
|
|
||||||
"version": "3.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz",
|
|
||||||
"integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/cli-truncate/node_modules/slice-ansi": {
|
|
||||||
"version": "3.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/slice-ansi/-/slice-ansi-3.0.0.tgz",
|
|
||||||
"integrity": "sha512-pSyv7bSTC7ig9Dcgbw9AuRNUb5k5V6oDudjZoMBSr13qpLBG7tB+zgCkARjq7xIUgdz5P1Qe8u+rSGdouOOIyQ==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"ansi-styles": "^4.0.0",
|
|
||||||
"astral-regex": "^2.0.0",
|
|
||||||
"is-fullwidth-code-point": "^3.0.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/cli-truncate/node_modules/string-width": {
|
|
||||||
"version": "4.2.2",
|
|
||||||
"resolved": "https://npm.ivanli.cc/string-width/-/string-width-4.2.2.tgz",
|
|
||||||
"integrity": "sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"emoji-regex": "^8.0.0",
|
|
||||||
"is-fullwidth-code-point": "^3.0.0",
|
|
||||||
"strip-ansi": "^6.0.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/cli-width": {
|
"node_modules/cli-width": {
|
||||||
"version": "3.0.0",
|
"version": "3.0.0",
|
||||||
"resolved": "https://npm.ivanli.cc/cli-width/-/cli-width-3.0.0.tgz",
|
"resolved": "https://npm.ivanli.cc/cli-width/-/cli-width-3.0.0.tgz",
|
||||||
@ -6495,9 +6417,9 @@
|
|||||||
"license": "MIT"
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"node_modules/colorette": {
|
"node_modules/colorette": {
|
||||||
"version": "1.4.0",
|
"version": "1.2.2",
|
||||||
"resolved": "https://npm.ivanli.cc/colorette/-/colorette-1.4.0.tgz",
|
"resolved": "https://npm.ivanli.cc/colorette/-/colorette-1.2.2.tgz",
|
||||||
"integrity": "sha512-Y2oEozpomLn7Q3HFP7dpww7AtMJplbM9lGZP6RDfHqmbeRjiwRg4n6VM6j4KLmRke85uWEI7JqF17f3pqdRA0g==",
|
"integrity": "sha512-MKGMzyfeuutC/ZJ1cba9NqcNpfeqMUcYmyF1ZFY6/Cn7CNSAKx6a+s48sqLqyAiZuaP2TcqMhoo+dlwFnVxT9w==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT"
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
@ -6599,10 +6521,6 @@
|
|||||||
"safe-buffer": "~5.1.0"
|
"safe-buffer": "~5.1.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/configuration": {
|
|
||||||
"resolved": "../configuration",
|
|
||||||
"link": true
|
|
||||||
},
|
|
||||||
"node_modules/consola": {
|
"node_modules/consola": {
|
||||||
"version": "2.15.3",
|
"version": "2.15.3",
|
||||||
"resolved": "https://npm.ivanli.cc/consola/-/consola-2.15.3.tgz",
|
"resolved": "https://npm.ivanli.cc/consola/-/consola-2.15.3.tgz",
|
||||||
@ -8876,13 +8794,6 @@
|
|||||||
"url": "https://github.com/sponsors/ljharb"
|
"url": "https://github.com/sponsors/ljharb"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/get-own-enumerable-property-symbols": {
|
|
||||||
"version": "3.0.2",
|
|
||||||
"resolved": "https://npm.ivanli.cc/get-own-enumerable-property-symbols/-/get-own-enumerable-property-symbols-3.0.2.tgz",
|
|
||||||
"integrity": "sha512-I0UBV/XOz1XkIJHEUDMZAbzCThU/H8DxmSfmdGcKPnVhu2VfFqr34jr9777IyaTYvxjedWhqVIilEDsCdP5G6g==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "ISC"
|
|
||||||
},
|
|
||||||
"node_modules/get-package-type": {
|
"node_modules/get-package-type": {
|
||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"resolved": "https://npm.ivanli.cc/get-package-type/-/get-package-type-0.1.0.tgz",
|
"resolved": "https://npm.ivanli.cc/get-package-type/-/get-package-type-0.1.0.tgz",
|
||||||
@ -9464,22 +9375,6 @@
|
|||||||
"ms": "^2.0.0"
|
"ms": "^2.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/husky": {
|
|
||||||
"version": "7.0.2",
|
|
||||||
"resolved": "https://npm.ivanli.cc/husky/-/husky-7.0.2.tgz",
|
|
||||||
"integrity": "sha512-8yKEWNX4z2YsofXAMT7KvA1g8p+GxtB1ffV8XtpAEGuXNAbCV5wdNKH+qTpw8SM9fh4aMPDR+yQuKfgnreyZlg==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"bin": {
|
|
||||||
"husky": "lib/bin.js"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=12"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"url": "https://github.com/sponsors/typicode"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/iconv-lite": {
|
"node_modules/iconv-lite": {
|
||||||
"version": "0.4.24",
|
"version": "0.4.24",
|
||||||
"resolved": "https://npm.ivanli.cc/iconv-lite/-/iconv-lite-0.4.24.tgz",
|
"resolved": "https://npm.ivanli.cc/iconv-lite/-/iconv-lite-0.4.24.tgz",
|
||||||
@ -9580,8 +9475,8 @@
|
|||||||
"version": "4.0.0",
|
"version": "4.0.0",
|
||||||
"resolved": "https://npm.ivanli.cc/indent-string/-/indent-string-4.0.0.tgz",
|
"resolved": "https://npm.ivanli.cc/indent-string/-/indent-string-4.0.0.tgz",
|
||||||
"integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==",
|
"integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==",
|
||||||
"devOptional": true,
|
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
|
"optional": true,
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=8"
|
"node": ">=8"
|
||||||
}
|
}
|
||||||
@ -10019,16 +9914,6 @@
|
|||||||
"url": "https://github.com/sponsors/ljharb"
|
"url": "https://github.com/sponsors/ljharb"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/is-obj": {
|
|
||||||
"version": "1.0.1",
|
|
||||||
"resolved": "https://npm.ivanli.cc/is-obj/-/is-obj-1.0.1.tgz",
|
|
||||||
"integrity": "sha1-PkcprB9f3gJc19g6iW2rn09n2w8=",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=0.10.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/is-plain-object": {
|
"node_modules/is-plain-object": {
|
||||||
"version": "2.0.4",
|
"version": "2.0.4",
|
||||||
"resolved": "https://npm.ivanli.cc/is-plain-object/-/is-plain-object-2.0.4.tgz",
|
"resolved": "https://npm.ivanli.cc/is-plain-object/-/is-plain-object-2.0.4.tgz",
|
||||||
@ -10065,16 +9950,6 @@
|
|||||||
"url": "https://github.com/sponsors/ljharb"
|
"url": "https://github.com/sponsors/ljharb"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/is-regexp": {
|
|
||||||
"version": "1.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/is-regexp/-/is-regexp-1.0.0.tgz",
|
|
||||||
"integrity": "sha1-/S2INUXEa6xaYz57mgnof6LLUGk=",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=0.10.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/is-set": {
|
"node_modules/is-set": {
|
||||||
"version": "2.0.2",
|
"version": "2.0.2",
|
||||||
"resolved": "https://npm.ivanli.cc/is-set/-/is-set-2.0.2.tgz",
|
"resolved": "https://npm.ivanli.cc/is-set/-/is-set-2.0.2.tgz",
|
||||||
@ -11487,207 +11362,6 @@
|
|||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT"
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"node_modules/lint-staged": {
|
|
||||||
"version": "11.1.2",
|
|
||||||
"resolved": "https://npm.ivanli.cc/lint-staged/-/lint-staged-11.1.2.tgz",
|
|
||||||
"integrity": "sha512-6lYpNoA9wGqkL6Hew/4n1H6lRqF3qCsujVT0Oq5Z4hiSAM7S6NksPJ3gnr7A7R52xCtiZMcEUNNQ6d6X5Bvh9w==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"chalk": "^4.1.1",
|
|
||||||
"cli-truncate": "^2.1.0",
|
|
||||||
"commander": "^7.2.0",
|
|
||||||
"cosmiconfig": "^7.0.0",
|
|
||||||
"debug": "^4.3.1",
|
|
||||||
"enquirer": "^2.3.6",
|
|
||||||
"execa": "^5.0.0",
|
|
||||||
"listr2": "^3.8.2",
|
|
||||||
"log-symbols": "^4.1.0",
|
|
||||||
"micromatch": "^4.0.4",
|
|
||||||
"normalize-path": "^3.0.0",
|
|
||||||
"please-upgrade-node": "^3.2.0",
|
|
||||||
"string-argv": "0.3.1",
|
|
||||||
"stringify-object": "^3.3.0"
|
|
||||||
},
|
|
||||||
"bin": {
|
|
||||||
"lint-staged": "bin/lint-staged.js"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"url": "https://opencollective.com/lint-staged"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/lint-staged/node_modules/chalk": {
|
|
||||||
"version": "4.1.2",
|
|
||||||
"resolved": "https://npm.ivanli.cc/chalk/-/chalk-4.1.2.tgz",
|
|
||||||
"integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"ansi-styles": "^4.1.0",
|
|
||||||
"supports-color": "^7.1.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"url": "https://github.com/chalk/chalk?sponsor=1"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/lint-staged/node_modules/commander": {
|
|
||||||
"version": "7.2.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/commander/-/commander-7.2.0.tgz",
|
|
||||||
"integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">= 10"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/lint-staged/node_modules/cosmiconfig": {
|
|
||||||
"version": "7.0.1",
|
|
||||||
"resolved": "https://npm.ivanli.cc/cosmiconfig/-/cosmiconfig-7.0.1.tgz",
|
|
||||||
"integrity": "sha512-a1YWNUV2HwGimB7dU2s1wUMurNKjpx60HxBB6xUM8Re+2s1g1IIfJvFR0/iCF+XHdE0GMTKTuLR32UQff4TEyQ==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"@types/parse-json": "^4.0.0",
|
|
||||||
"import-fresh": "^3.2.1",
|
|
||||||
"parse-json": "^5.0.0",
|
|
||||||
"path-type": "^4.0.0",
|
|
||||||
"yaml": "^1.10.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/lint-staged/node_modules/execa": {
|
|
||||||
"version": "5.1.1",
|
|
||||||
"resolved": "https://npm.ivanli.cc/execa/-/execa-5.1.1.tgz",
|
|
||||||
"integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"cross-spawn": "^7.0.3",
|
|
||||||
"get-stream": "^6.0.0",
|
|
||||||
"human-signals": "^2.1.0",
|
|
||||||
"is-stream": "^2.0.0",
|
|
||||||
"merge-stream": "^2.0.0",
|
|
||||||
"npm-run-path": "^4.0.1",
|
|
||||||
"onetime": "^5.1.2",
|
|
||||||
"signal-exit": "^3.0.3",
|
|
||||||
"strip-final-newline": "^2.0.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"url": "https://github.com/sindresorhus/execa?sponsor=1"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/lint-staged/node_modules/get-stream": {
|
|
||||||
"version": "6.0.1",
|
|
||||||
"resolved": "https://npm.ivanli.cc/get-stream/-/get-stream-6.0.1.tgz",
|
|
||||||
"integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"url": "https://github.com/sponsors/sindresorhus"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/lint-staged/node_modules/human-signals": {
|
|
||||||
"version": "2.1.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/human-signals/-/human-signals-2.1.0.tgz",
|
|
||||||
"integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "Apache-2.0",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10.17.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/listr2": {
|
|
||||||
"version": "3.12.1",
|
|
||||||
"resolved": "https://npm.ivanli.cc/listr2/-/listr2-3.12.1.tgz",
|
|
||||||
"integrity": "sha512-oB1DlXlCzGPbvWhqYBZUQEPJKqsmebQWofXG6Mpbe3uIvoNl8mctBEojyF13ZyqwQ91clCWXpwsWp+t98K4FOQ==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"cli-truncate": "^2.1.0",
|
|
||||||
"colorette": "^1.4.0",
|
|
||||||
"log-update": "^4.0.0",
|
|
||||||
"p-map": "^4.0.0",
|
|
||||||
"rxjs": "^6.6.7",
|
|
||||||
"through": "^2.3.8",
|
|
||||||
"wrap-ansi": "^7.0.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10.0.0"
|
|
||||||
},
|
|
||||||
"peerDependencies": {
|
|
||||||
"enquirer": ">= 2.3.0 < 3"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/listr2/node_modules/is-fullwidth-code-point": {
|
|
||||||
"version": "3.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz",
|
|
||||||
"integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/listr2/node_modules/p-map": {
|
|
||||||
"version": "4.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/p-map/-/p-map-4.0.0.tgz",
|
|
||||||
"integrity": "sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"aggregate-error": "^3.0.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"url": "https://github.com/sponsors/sindresorhus"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/listr2/node_modules/string-width": {
|
|
||||||
"version": "4.2.2",
|
|
||||||
"resolved": "https://npm.ivanli.cc/string-width/-/string-width-4.2.2.tgz",
|
|
||||||
"integrity": "sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"emoji-regex": "^8.0.0",
|
|
||||||
"is-fullwidth-code-point": "^3.0.0",
|
|
||||||
"strip-ansi": "^6.0.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=8"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/listr2/node_modules/wrap-ansi": {
|
|
||||||
"version": "7.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/wrap-ansi/-/wrap-ansi-7.0.0.tgz",
|
|
||||||
"integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"ansi-styles": "^4.0.0",
|
|
||||||
"string-width": "^4.1.0",
|
|
||||||
"strip-ansi": "^6.0.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"url": "https://github.com/chalk/wrap-ansi?sponsor=1"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/loader-runner": {
|
"node_modules/loader-runner": {
|
||||||
"version": "4.2.0",
|
"version": "4.2.0",
|
||||||
"resolved": "https://npm.ivanli.cc/loader-runner/-/loader-runner-4.2.0.tgz",
|
"resolved": "https://npm.ivanli.cc/loader-runner/-/loader-runner-4.2.0.tgz",
|
||||||
@ -11858,25 +11532,6 @@
|
|||||||
"url": "https://github.com/chalk/chalk?sponsor=1"
|
"url": "https://github.com/chalk/chalk?sponsor=1"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/log-update": {
|
|
||||||
"version": "4.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/log-update/-/log-update-4.0.0.tgz",
|
|
||||||
"integrity": "sha512-9fkkDevMefjg0mmzWFBW8YkFP91OrizzkW3diF7CpG+S2EYdy4+TVfGwz1zeF8x7hCx1ovSPTOE9Ngib74qqUg==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"ansi-escapes": "^4.3.0",
|
|
||||||
"cli-cursor": "^3.1.0",
|
|
||||||
"slice-ansi": "^4.0.0",
|
|
||||||
"wrap-ansi": "^6.2.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=10"
|
|
||||||
},
|
|
||||||
"funding": {
|
|
||||||
"url": "https://github.com/sponsors/sindresorhus"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/loglevel": {
|
"node_modules/loglevel": {
|
||||||
"version": "1.7.1",
|
"version": "1.7.1",
|
||||||
"resolved": "https://npm.ivanli.cc/loglevel/-/loglevel-1.7.1.tgz",
|
"resolved": "https://npm.ivanli.cc/loglevel/-/loglevel-1.7.1.tgz",
|
||||||
@ -13674,16 +13329,6 @@
|
|||||||
"node": ">=8"
|
"node": ">=8"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/please-upgrade-node": {
|
|
||||||
"version": "3.2.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/please-upgrade-node/-/please-upgrade-node-3.2.0.tgz",
|
|
||||||
"integrity": "sha512-gQR3WpIgNIKwBMVLkpMUeR3e1/E1y42bqDQZfql+kDeXd8COYfM8PQA4X6y7a8u9Ua9FHmsrrmirW2vHs45hWg==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"dependencies": {
|
|
||||||
"semver-compare": "^1.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/pluralize": {
|
"node_modules/pluralize": {
|
||||||
"version": "8.0.0",
|
"version": "8.0.0",
|
||||||
"resolved": "https://npm.ivanli.cc/pluralize/-/pluralize-8.0.0.tgz",
|
"resolved": "https://npm.ivanli.cc/pluralize/-/pluralize-8.0.0.tgz",
|
||||||
@ -15078,13 +14723,6 @@
|
|||||||
"node": ">=10"
|
"node": ">=10"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/semver-compare": {
|
|
||||||
"version": "1.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/semver-compare/-/semver-compare-1.0.0.tgz",
|
|
||||||
"integrity": "sha1-De4hahyUGrN+nvsXiPavxf9VN/w=",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT"
|
|
||||||
},
|
|
||||||
"node_modules/send": {
|
"node_modules/send": {
|
||||||
"version": "0.17.1",
|
"version": "0.17.1",
|
||||||
"resolved": "https://npm.ivanli.cc/send/-/send-0.17.1.tgz",
|
"resolved": "https://npm.ivanli.cc/send/-/send-0.17.1.tgz",
|
||||||
@ -15964,16 +15602,6 @@
|
|||||||
"integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=",
|
"integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ=",
|
||||||
"license": "MIT"
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"node_modules/string-argv": {
|
|
||||||
"version": "0.3.1",
|
|
||||||
"resolved": "https://npm.ivanli.cc/string-argv/-/string-argv-0.3.1.tgz",
|
|
||||||
"integrity": "sha512-a1uQGz7IyVy9YwhqjZIZu1c8JO8dNIe20xBmSS6qu9kv++k3JGzCVmprbNN5Kn+BgzD5E7YYwg1CcjuJMRNsvg==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "MIT",
|
|
||||||
"engines": {
|
|
||||||
"node": ">=0.6.19"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/string-length": {
|
"node_modules/string-length": {
|
||||||
"version": "4.0.2",
|
"version": "4.0.2",
|
||||||
"resolved": "https://npm.ivanli.cc/string-length/-/string-length-4.0.2.tgz",
|
"resolved": "https://npm.ivanli.cc/string-length/-/string-length-4.0.2.tgz",
|
||||||
@ -16048,21 +15676,6 @@
|
|||||||
"url": "https://github.com/sponsors/ljharb"
|
"url": "https://github.com/sponsors/ljharb"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/stringify-object": {
|
|
||||||
"version": "3.3.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/stringify-object/-/stringify-object-3.3.0.tgz",
|
|
||||||
"integrity": "sha512-rHqiFh1elqCQ9WPLIC8I0Q/g/wj5J1eMkyoiD6eoQApWHP0FtlK7rqnhmabL5VUY9JQCcqwwvlOaSuutekgyrw==",
|
|
||||||
"dev": true,
|
|
||||||
"license": "BSD-2-Clause",
|
|
||||||
"dependencies": {
|
|
||||||
"get-own-enumerable-property-symbols": "^3.0.0",
|
|
||||||
"is-obj": "^1.0.1",
|
|
||||||
"is-regexp": "^1.0.0"
|
|
||||||
},
|
|
||||||
"engines": {
|
|
||||||
"node": ">=4"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"node_modules/strip-ansi": {
|
"node_modules/strip-ansi": {
|
||||||
"version": "6.0.0",
|
"version": "6.0.0",
|
||||||
"resolved": "https://npm.ivanli.cc/strip-ansi/-/strip-ansi-6.0.0.tgz",
|
"resolved": "https://npm.ivanli.cc/strip-ansi/-/strip-ansi-6.0.0.tgz",
|
||||||
@ -21536,7 +21149,7 @@
|
|||||||
"version": "3.1.0",
|
"version": "3.1.0",
|
||||||
"resolved": "https://npm.ivanli.cc/aggregate-error/-/aggregate-error-3.1.0.tgz",
|
"resolved": "https://npm.ivanli.cc/aggregate-error/-/aggregate-error-3.1.0.tgz",
|
||||||
"integrity": "sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==",
|
"integrity": "sha512-4I7Td01quW/RpocfNayFdFVk1qSuoh0E7JrbRJ16nH01HhKFQ88INq9Sd+nd72zqRySlr9BmDA8xlEJ6vJMrYA==",
|
||||||
"devOptional": true,
|
"optional": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"clean-stack": "^2.0.0",
|
"clean-stack": "^2.0.0",
|
||||||
"indent-string": "^4.0.0"
|
"indent-string": "^4.0.0"
|
||||||
@ -22817,7 +22430,7 @@
|
|||||||
"version": "2.2.0",
|
"version": "2.2.0",
|
||||||
"resolved": "https://npm.ivanli.cc/clean-stack/-/clean-stack-2.2.0.tgz",
|
"resolved": "https://npm.ivanli.cc/clean-stack/-/clean-stack-2.2.0.tgz",
|
||||||
"integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==",
|
"integrity": "sha512-4diC9HaTE+KRAMWhDhrGOECgWZxoevMc5TlkObMqNSsVU62PYzXZ/SMTjzyGAFF1YusgxGcSWTEXBhp0CPwQ1A==",
|
||||||
"devOptional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"cli-cursor": {
|
"cli-cursor": {
|
||||||
"version": "3.1.0",
|
"version": "3.1.0",
|
||||||
@ -22936,46 +22549,6 @@
|
|||||||
"chalk": "3.0.0"
|
"chalk": "3.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"cli-truncate": {
|
|
||||||
"version": "2.1.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/cli-truncate/-/cli-truncate-2.1.0.tgz",
|
|
||||||
"integrity": "sha512-n8fOixwDD6b/ObinzTrp1ZKFzbgvKZvuz/TvejnLn1aQfC6r52XEx85FmuC+3HI+JM7coBRXUvNqEU2PHVrHpg==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"slice-ansi": "^3.0.0",
|
|
||||||
"string-width": "^4.2.0"
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"is-fullwidth-code-point": {
|
|
||||||
"version": "3.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz",
|
|
||||||
"integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"slice-ansi": {
|
|
||||||
"version": "3.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/slice-ansi/-/slice-ansi-3.0.0.tgz",
|
|
||||||
"integrity": "sha512-pSyv7bSTC7ig9Dcgbw9AuRNUb5k5V6oDudjZoMBSr13qpLBG7tB+zgCkARjq7xIUgdz5P1Qe8u+rSGdouOOIyQ==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"ansi-styles": "^4.0.0",
|
|
||||||
"astral-regex": "^2.0.0",
|
|
||||||
"is-fullwidth-code-point": "^3.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"string-width": {
|
|
||||||
"version": "4.2.2",
|
|
||||||
"resolved": "https://npm.ivanli.cc/string-width/-/string-width-4.2.2.tgz",
|
|
||||||
"integrity": "sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"emoji-regex": "^8.0.0",
|
|
||||||
"is-fullwidth-code-point": "^3.0.0",
|
|
||||||
"strip-ansi": "^6.0.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"cli-width": {
|
"cli-width": {
|
||||||
"version": "3.0.0",
|
"version": "3.0.0",
|
||||||
"resolved": "https://npm.ivanli.cc/cli-width/-/cli-width-3.0.0.tgz",
|
"resolved": "https://npm.ivanli.cc/cli-width/-/cli-width-3.0.0.tgz",
|
||||||
@ -23092,9 +22665,9 @@
|
|||||||
"integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA=="
|
"integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA=="
|
||||||
},
|
},
|
||||||
"colorette": {
|
"colorette": {
|
||||||
"version": "1.4.0",
|
"version": "1.2.2",
|
||||||
"resolved": "https://npm.ivanli.cc/colorette/-/colorette-1.4.0.tgz",
|
"resolved": "https://npm.ivanli.cc/colorette/-/colorette-1.2.2.tgz",
|
||||||
"integrity": "sha512-Y2oEozpomLn7Q3HFP7dpww7AtMJplbM9lGZP6RDfHqmbeRjiwRg4n6VM6j4KLmRke85uWEI7JqF17f3pqdRA0g==",
|
"integrity": "sha512-MKGMzyfeuutC/ZJ1cba9NqcNpfeqMUcYmyF1ZFY6/Cn7CNSAKx6a+s48sqLqyAiZuaP2TcqMhoo+dlwFnVxT9w==",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"colors": {
|
"colors": {
|
||||||
@ -23175,21 +22748,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"configuration": {
|
|
||||||
"version": "file:../configuration",
|
|
||||||
"requires": {
|
|
||||||
"@tsconfig/node14": "^1.0.1",
|
|
||||||
"@types/debug": "^4.1.7",
|
|
||||||
"@types/js-yaml": "^4.0.3",
|
|
||||||
"@types/node": "^14.17.17",
|
|
||||||
"debug": "^4.3.2",
|
|
||||||
"etcd3": "^1.1.0",
|
|
||||||
"js-yaml": "^4.1.0",
|
|
||||||
"rimraf": "^3.0.2",
|
|
||||||
"ts-node": "^10.2.1",
|
|
||||||
"typescript": "^4.4.4"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"consola": {
|
"consola": {
|
||||||
"version": "2.15.3",
|
"version": "2.15.3",
|
||||||
"resolved": "https://npm.ivanli.cc/consola/-/consola-2.15.3.tgz",
|
"resolved": "https://npm.ivanli.cc/consola/-/consola-2.15.3.tgz",
|
||||||
@ -24826,12 +24384,6 @@
|
|||||||
"has-symbols": "^1.0.1"
|
"has-symbols": "^1.0.1"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"get-own-enumerable-property-symbols": {
|
|
||||||
"version": "3.0.2",
|
|
||||||
"resolved": "https://npm.ivanli.cc/get-own-enumerable-property-symbols/-/get-own-enumerable-property-symbols-3.0.2.tgz",
|
|
||||||
"integrity": "sha512-I0UBV/XOz1XkIJHEUDMZAbzCThU/H8DxmSfmdGcKPnVhu2VfFqr34jr9777IyaTYvxjedWhqVIilEDsCdP5G6g==",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"get-package-type": {
|
"get-package-type": {
|
||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"resolved": "https://npm.ivanli.cc/get-package-type/-/get-package-type-0.1.0.tgz",
|
"resolved": "https://npm.ivanli.cc/get-package-type/-/get-package-type-0.1.0.tgz",
|
||||||
@ -25241,12 +24793,6 @@
|
|||||||
"ms": "^2.0.0"
|
"ms": "^2.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"husky": {
|
|
||||||
"version": "7.0.2",
|
|
||||||
"resolved": "https://npm.ivanli.cc/husky/-/husky-7.0.2.tgz",
|
|
||||||
"integrity": "sha512-8yKEWNX4z2YsofXAMT7KvA1g8p+GxtB1ffV8XtpAEGuXNAbCV5wdNKH+qTpw8SM9fh4aMPDR+yQuKfgnreyZlg==",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"iconv-lite": {
|
"iconv-lite": {
|
||||||
"version": "0.4.24",
|
"version": "0.4.24",
|
||||||
"resolved": "https://npm.ivanli.cc/iconv-lite/-/iconv-lite-0.4.24.tgz",
|
"resolved": "https://npm.ivanli.cc/iconv-lite/-/iconv-lite-0.4.24.tgz",
|
||||||
@ -25304,7 +24850,7 @@
|
|||||||
"version": "4.0.0",
|
"version": "4.0.0",
|
||||||
"resolved": "https://npm.ivanli.cc/indent-string/-/indent-string-4.0.0.tgz",
|
"resolved": "https://npm.ivanli.cc/indent-string/-/indent-string-4.0.0.tgz",
|
||||||
"integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==",
|
"integrity": "sha512-EdDDZu4A2OyIK7Lr/2zG+w5jmbuk1DVBnEwREQvBzspBJkCEbRa8GxU1lghYcaGJCnRWibjDXlq779X1/y5xwg==",
|
||||||
"devOptional": true
|
"optional": true
|
||||||
},
|
},
|
||||||
"infer-owner": {
|
"infer-owner": {
|
||||||
"version": "1.0.4",
|
"version": "1.0.4",
|
||||||
@ -25586,12 +25132,6 @@
|
|||||||
"resolved": "https://npm.ivanli.cc/is-number-object/-/is-number-object-1.0.5.tgz",
|
"resolved": "https://npm.ivanli.cc/is-number-object/-/is-number-object-1.0.5.tgz",
|
||||||
"integrity": "sha512-RU0lI/n95pMoUKu9v1BZP5MBcZuNSVJkMkAG2dJqC4z2GlkGUNeH68SuHuBKBD/XFe+LHZ+f9BKkLET60Niedw=="
|
"integrity": "sha512-RU0lI/n95pMoUKu9v1BZP5MBcZuNSVJkMkAG2dJqC4z2GlkGUNeH68SuHuBKBD/XFe+LHZ+f9BKkLET60Niedw=="
|
||||||
},
|
},
|
||||||
"is-obj": {
|
|
||||||
"version": "1.0.1",
|
|
||||||
"resolved": "https://npm.ivanli.cc/is-obj/-/is-obj-1.0.1.tgz",
|
|
||||||
"integrity": "sha1-PkcprB9f3gJc19g6iW2rn09n2w8=",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"is-plain-object": {
|
"is-plain-object": {
|
||||||
"version": "2.0.4",
|
"version": "2.0.4",
|
||||||
"resolved": "https://npm.ivanli.cc/is-plain-object/-/is-plain-object-2.0.4.tgz",
|
"resolved": "https://npm.ivanli.cc/is-plain-object/-/is-plain-object-2.0.4.tgz",
|
||||||
@ -25616,12 +25156,6 @@
|
|||||||
"has-symbols": "^1.0.2"
|
"has-symbols": "^1.0.2"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"is-regexp": {
|
|
||||||
"version": "1.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/is-regexp/-/is-regexp-1.0.0.tgz",
|
|
||||||
"integrity": "sha1-/S2INUXEa6xaYz57mgnof6LLUGk=",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"is-set": {
|
"is-set": {
|
||||||
"version": "2.0.2",
|
"version": "2.0.2",
|
||||||
"resolved": "https://npm.ivanli.cc/is-set/-/is-set-2.0.2.tgz",
|
"resolved": "https://npm.ivanli.cc/is-set/-/is-set-2.0.2.tgz",
|
||||||
@ -26654,142 +26188,6 @@
|
|||||||
"integrity": "sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA=",
|
"integrity": "sha1-HADHQ7QzzQpOgHWPe2SldEDZ/wA=",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"lint-staged": {
|
|
||||||
"version": "11.1.2",
|
|
||||||
"resolved": "https://npm.ivanli.cc/lint-staged/-/lint-staged-11.1.2.tgz",
|
|
||||||
"integrity": "sha512-6lYpNoA9wGqkL6Hew/4n1H6lRqF3qCsujVT0Oq5Z4hiSAM7S6NksPJ3gnr7A7R52xCtiZMcEUNNQ6d6X5Bvh9w==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"chalk": "^4.1.1",
|
|
||||||
"cli-truncate": "^2.1.0",
|
|
||||||
"commander": "^7.2.0",
|
|
||||||
"cosmiconfig": "^7.0.0",
|
|
||||||
"debug": "^4.3.1",
|
|
||||||
"enquirer": "^2.3.6",
|
|
||||||
"execa": "^5.0.0",
|
|
||||||
"listr2": "^3.8.2",
|
|
||||||
"log-symbols": "^4.1.0",
|
|
||||||
"micromatch": "^4.0.4",
|
|
||||||
"normalize-path": "^3.0.0",
|
|
||||||
"please-upgrade-node": "^3.2.0",
|
|
||||||
"string-argv": "0.3.1",
|
|
||||||
"stringify-object": "^3.3.0"
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"chalk": {
|
|
||||||
"version": "4.1.2",
|
|
||||||
"resolved": "https://npm.ivanli.cc/chalk/-/chalk-4.1.2.tgz",
|
|
||||||
"integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"ansi-styles": "^4.1.0",
|
|
||||||
"supports-color": "^7.1.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"commander": {
|
|
||||||
"version": "7.2.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/commander/-/commander-7.2.0.tgz",
|
|
||||||
"integrity": "sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"cosmiconfig": {
|
|
||||||
"version": "7.0.1",
|
|
||||||
"resolved": "https://npm.ivanli.cc/cosmiconfig/-/cosmiconfig-7.0.1.tgz",
|
|
||||||
"integrity": "sha512-a1YWNUV2HwGimB7dU2s1wUMurNKjpx60HxBB6xUM8Re+2s1g1IIfJvFR0/iCF+XHdE0GMTKTuLR32UQff4TEyQ==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"@types/parse-json": "^4.0.0",
|
|
||||||
"import-fresh": "^3.2.1",
|
|
||||||
"parse-json": "^5.0.0",
|
|
||||||
"path-type": "^4.0.0",
|
|
||||||
"yaml": "^1.10.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"execa": {
|
|
||||||
"version": "5.1.1",
|
|
||||||
"resolved": "https://npm.ivanli.cc/execa/-/execa-5.1.1.tgz",
|
|
||||||
"integrity": "sha512-8uSpZZocAZRBAPIEINJj3Lo9HyGitllczc27Eh5YYojjMFMn8yHMDMaUHE2Jqfq05D/wucwI4JGURyXt1vchyg==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"cross-spawn": "^7.0.3",
|
|
||||||
"get-stream": "^6.0.0",
|
|
||||||
"human-signals": "^2.1.0",
|
|
||||||
"is-stream": "^2.0.0",
|
|
||||||
"merge-stream": "^2.0.0",
|
|
||||||
"npm-run-path": "^4.0.1",
|
|
||||||
"onetime": "^5.1.2",
|
|
||||||
"signal-exit": "^3.0.3",
|
|
||||||
"strip-final-newline": "^2.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"get-stream": {
|
|
||||||
"version": "6.0.1",
|
|
||||||
"resolved": "https://npm.ivanli.cc/get-stream/-/get-stream-6.0.1.tgz",
|
|
||||||
"integrity": "sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg==",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"human-signals": {
|
|
||||||
"version": "2.1.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/human-signals/-/human-signals-2.1.0.tgz",
|
|
||||||
"integrity": "sha512-B4FFZ6q/T2jhhksgkbEW3HBvWIfDW85snkQgawt07S7J5QXTk6BkNV+0yAeZrM5QpMAdYlocGoljn0sJ/WQkFw==",
|
|
||||||
"dev": true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"listr2": {
|
|
||||||
"version": "3.12.1",
|
|
||||||
"resolved": "https://npm.ivanli.cc/listr2/-/listr2-3.12.1.tgz",
|
|
||||||
"integrity": "sha512-oB1DlXlCzGPbvWhqYBZUQEPJKqsmebQWofXG6Mpbe3uIvoNl8mctBEojyF13ZyqwQ91clCWXpwsWp+t98K4FOQ==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"cli-truncate": "^2.1.0",
|
|
||||||
"colorette": "^1.4.0",
|
|
||||||
"log-update": "^4.0.0",
|
|
||||||
"p-map": "^4.0.0",
|
|
||||||
"rxjs": "^6.6.7",
|
|
||||||
"through": "^2.3.8",
|
|
||||||
"wrap-ansi": "^7.0.0"
|
|
||||||
},
|
|
||||||
"dependencies": {
|
|
||||||
"is-fullwidth-code-point": {
|
|
||||||
"version": "3.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz",
|
|
||||||
"integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"p-map": {
|
|
||||||
"version": "4.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/p-map/-/p-map-4.0.0.tgz",
|
|
||||||
"integrity": "sha512-/bjOqmgETBYB5BoEeGVea8dmvHb2m9GLy1E9W43yeyfP6QQCZGFNa+XRceJEuDB6zqr+gKpIAmlLebMpykw/MQ==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"aggregate-error": "^3.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"string-width": {
|
|
||||||
"version": "4.2.2",
|
|
||||||
"resolved": "https://npm.ivanli.cc/string-width/-/string-width-4.2.2.tgz",
|
|
||||||
"integrity": "sha512-XBJbT3N4JhVumXE0eoLU9DCjcaF92KLNqTmFCnG1pf8duUxFGwtP6AD6nkjw9a3IdiRtL3E2w3JDiE/xi3vOeA==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"emoji-regex": "^8.0.0",
|
|
||||||
"is-fullwidth-code-point": "^3.0.0",
|
|
||||||
"strip-ansi": "^6.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"wrap-ansi": {
|
|
||||||
"version": "7.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/wrap-ansi/-/wrap-ansi-7.0.0.tgz",
|
|
||||||
"integrity": "sha512-YVGIj2kamLSTxw6NsZjoBxfSwsn0ycdesmc4p+Q21c5zPuZ1pl+NfxVdxPtdHvmNVOQ6XSYG4AUtyt/Fi7D16Q==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"ansi-styles": "^4.0.0",
|
|
||||||
"string-width": "^4.1.0",
|
|
||||||
"strip-ansi": "^6.0.0"
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"loader-runner": {
|
"loader-runner": {
|
||||||
"version": "4.2.0",
|
"version": "4.2.0",
|
||||||
"resolved": "https://npm.ivanli.cc/loader-runner/-/loader-runner-4.2.0.tgz",
|
"resolved": "https://npm.ivanli.cc/loader-runner/-/loader-runner-4.2.0.tgz",
|
||||||
@ -26918,18 +26316,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"log-update": {
|
|
||||||
"version": "4.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/log-update/-/log-update-4.0.0.tgz",
|
|
||||||
"integrity": "sha512-9fkkDevMefjg0mmzWFBW8YkFP91OrizzkW3diF7CpG+S2EYdy4+TVfGwz1zeF8x7hCx1ovSPTOE9Ngib74qqUg==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"ansi-escapes": "^4.3.0",
|
|
||||||
"cli-cursor": "^3.1.0",
|
|
||||||
"slice-ansi": "^4.0.0",
|
|
||||||
"wrap-ansi": "^6.2.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"loglevel": {
|
"loglevel": {
|
||||||
"version": "1.7.1",
|
"version": "1.7.1",
|
||||||
"resolved": "https://npm.ivanli.cc/loglevel/-/loglevel-1.7.1.tgz",
|
"resolved": "https://npm.ivanli.cc/loglevel/-/loglevel-1.7.1.tgz",
|
||||||
@ -28208,15 +27594,6 @@
|
|||||||
"find-up": "^4.0.0"
|
"find-up": "^4.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"please-upgrade-node": {
|
|
||||||
"version": "3.2.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/please-upgrade-node/-/please-upgrade-node-3.2.0.tgz",
|
|
||||||
"integrity": "sha512-gQR3WpIgNIKwBMVLkpMUeR3e1/E1y42bqDQZfql+kDeXd8COYfM8PQA4X6y7a8u9Ua9FHmsrrmirW2vHs45hWg==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"semver-compare": "^1.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"pluralize": {
|
"pluralize": {
|
||||||
"version": "8.0.0",
|
"version": "8.0.0",
|
||||||
"resolved": "https://npm.ivanli.cc/pluralize/-/pluralize-8.0.0.tgz",
|
"resolved": "https://npm.ivanli.cc/pluralize/-/pluralize-8.0.0.tgz",
|
||||||
@ -29201,12 +28578,6 @@
|
|||||||
"lru-cache": "^6.0.0"
|
"lru-cache": "^6.0.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"semver-compare": {
|
|
||||||
"version": "1.0.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/semver-compare/-/semver-compare-1.0.0.tgz",
|
|
||||||
"integrity": "sha1-De4hahyUGrN+nvsXiPavxf9VN/w=",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"send": {
|
"send": {
|
||||||
"version": "0.17.1",
|
"version": "0.17.1",
|
||||||
"resolved": "https://npm.ivanli.cc/send/-/send-0.17.1.tgz",
|
"resolved": "https://npm.ivanli.cc/send/-/send-0.17.1.tgz",
|
||||||
@ -29883,12 +29254,6 @@
|
|||||||
"resolved": "https://npm.ivanli.cc/string_decoder/-/string_decoder-0.10.31.tgz",
|
"resolved": "https://npm.ivanli.cc/string_decoder/-/string_decoder-0.10.31.tgz",
|
||||||
"integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ="
|
"integrity": "sha1-YuIDvEF2bGwoyfyEMB2rHFMQ+pQ="
|
||||||
},
|
},
|
||||||
"string-argv": {
|
|
||||||
"version": "0.3.1",
|
|
||||||
"resolved": "https://npm.ivanli.cc/string-argv/-/string-argv-0.3.1.tgz",
|
|
||||||
"integrity": "sha512-a1uQGz7IyVy9YwhqjZIZu1c8JO8dNIe20xBmSS6qu9kv++k3JGzCVmprbNN5Kn+BgzD5E7YYwg1CcjuJMRNsvg==",
|
|
||||||
"dev": true
|
|
||||||
},
|
|
||||||
"string-length": {
|
"string-length": {
|
||||||
"version": "4.0.2",
|
"version": "4.0.2",
|
||||||
"resolved": "https://npm.ivanli.cc/string-length/-/string-length-4.0.2.tgz",
|
"resolved": "https://npm.ivanli.cc/string-length/-/string-length-4.0.2.tgz",
|
||||||
@ -29941,17 +29306,6 @@
|
|||||||
"define-properties": "^1.1.3"
|
"define-properties": "^1.1.3"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"stringify-object": {
|
|
||||||
"version": "3.3.0",
|
|
||||||
"resolved": "https://npm.ivanli.cc/stringify-object/-/stringify-object-3.3.0.tgz",
|
|
||||||
"integrity": "sha512-rHqiFh1elqCQ9WPLIC8I0Q/g/wj5J1eMkyoiD6eoQApWHP0FtlK7rqnhmabL5VUY9JQCcqwwvlOaSuutekgyrw==",
|
|
||||||
"dev": true,
|
|
||||||
"requires": {
|
|
||||||
"get-own-enumerable-property-symbols": "^3.0.0",
|
|
||||||
"is-obj": "^1.0.1",
|
|
||||||
"is-regexp": "^1.0.0"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"strip-ansi": {
|
"strip-ansi": {
|
||||||
"version": "6.0.0",
|
"version": "6.0.0",
|
||||||
"resolved": "https://npm.ivanli.cc/strip-ansi/-/strip-ansi-6.0.0.tgz",
|
"resolved": "https://npm.ivanli.cc/strip-ansi/-/strip-ansi-6.0.0.tgz",
|
||||||
|
@ -18,8 +18,7 @@
|
|||||||
"test:watch": "jest --watch",
|
"test:watch": "jest --watch",
|
||||||
"test:cov": "jest --coverage",
|
"test:cov": "jest --coverage",
|
||||||
"test:debug": "node --inspect-brk -r tsconfig-paths/register -r ts-node/register node_modules/.bin/jest --runInBand",
|
"test:debug": "node --inspect-brk -r tsconfig-paths/register -r ts-node/register node_modules/.bin/jest --runInBand",
|
||||||
"test:e2e": "jest --config ./test/jest-e2e.json",
|
"test:e2e": "jest --config ./test/jest-e2e.json"
|
||||||
"prepare": "husky install"
|
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@golevelup/nestjs-rabbitmq": "^1.16.1",
|
"@golevelup/nestjs-rabbitmq": "^1.16.1",
|
||||||
@ -37,7 +36,6 @@
|
|||||||
"body-parser": "^1.19.0",
|
"body-parser": "^1.19.0",
|
||||||
"class-transformer": "^0.3.2",
|
"class-transformer": "^0.3.2",
|
||||||
"class-validator": "^0.13.1",
|
"class-validator": "^0.13.1",
|
||||||
"configuration": "file:../configuration",
|
|
||||||
"debug": "^4.3.1",
|
"debug": "^4.3.1",
|
||||||
"graphql": "^15.5.0",
|
"graphql": "^15.5.0",
|
||||||
"graphql-tools": "^8.1.0",
|
"graphql-tools": "^8.1.0",
|
||||||
@ -76,9 +74,7 @@
|
|||||||
"eslint": "^7.12.1",
|
"eslint": "^7.12.1",
|
||||||
"eslint-config-prettier": "7.2.0",
|
"eslint-config-prettier": "7.2.0",
|
||||||
"eslint-plugin-prettier": "^3.1.4",
|
"eslint-plugin-prettier": "^3.1.4",
|
||||||
"husky": "^7.0.2",
|
|
||||||
"jest": "^26.6.3",
|
"jest": "^26.6.3",
|
||||||
"lint-staged": "^11.1.2",
|
|
||||||
"prettier": "^2.1.2",
|
"prettier": "^2.1.2",
|
||||||
"supertest": "^6.0.0",
|
"supertest": "^6.0.0",
|
||||||
"ts-jest": "^26.4.3",
|
"ts-jest": "^26.4.3",
|
||||||
@ -106,8 +102,5 @@
|
|||||||
},
|
},
|
||||||
"coverageDirectory": "../coverage",
|
"coverageDirectory": "../coverage",
|
||||||
"testEnvironment": "node"
|
"testEnvironment": "node"
|
||||||
},
|
|
||||||
"lint-staged": {
|
|
||||||
"{src,apps,libs,test}/**/*.ts": "eslint --cache --fix"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -20,7 +20,6 @@ import { LoggerModule } from 'nestjs-pino';
|
|||||||
import { EtcdModule } from 'nestjs-etcd';
|
import { EtcdModule } from 'nestjs-etcd';
|
||||||
import pinoPretty from 'pino-pretty';
|
import pinoPretty from 'pino-pretty';
|
||||||
import { fromPairs, map, pipe, toPairs } from 'ramda';
|
import { fromPairs, map, pipe, toPairs } from 'ramda';
|
||||||
import { ConfigurationsModule } from './configurations/configurations.module';
|
|
||||||
|
|
||||||
@Module({
|
@Module({
|
||||||
imports: [
|
imports: [
|
||||||
@ -65,7 +64,7 @@ import { ConfigurationsModule } from './configurations/configurations.module';
|
|||||||
playground: true,
|
playground: true,
|
||||||
autoSchemaFile: true,
|
autoSchemaFile: true,
|
||||||
installSubscriptionHandlers: true,
|
installSubscriptionHandlers: true,
|
||||||
context: ({ req, connection }) => {
|
context: ({ req, connection, ...args }) => {
|
||||||
return connection ? { req: connection.context } : { req };
|
return connection ? { req: connection.context } : { req };
|
||||||
},
|
},
|
||||||
subscriptions: {
|
subscriptions: {
|
||||||
@ -107,7 +106,6 @@ import { ConfigurationsModule } from './configurations/configurations.module';
|
|||||||
}),
|
}),
|
||||||
WebhooksModule,
|
WebhooksModule,
|
||||||
CommonsModule,
|
CommonsModule,
|
||||||
ConfigurationsModule,
|
|
||||||
],
|
],
|
||||||
controllers: [AppController],
|
controllers: [AppController],
|
||||||
providers: [AppService, AppResolver],
|
providers: [AppService, AppResolver],
|
||||||
|
@ -1,9 +1,8 @@
|
|||||||
import { Global, Module } from '@nestjs/common';
|
import { Module } from '@nestjs/common';
|
||||||
import { PasswordConverter } from './services/password-converter';
|
import { PasswordConverter } from './services/password-converter';
|
||||||
import { RedisMutexModule } from './redis-mutex/redis-mutex.module';
|
import { RedisMutexModule } from './redis-mutex/redis-mutex.module';
|
||||||
import { AuthModule } from '@nestjs-lib/auth';
|
import { AuthModule } from '@nestjs-lib/auth';
|
||||||
|
|
||||||
@Global()
|
|
||||||
@Module({
|
@Module({
|
||||||
imports: [RedisMutexModule, AuthModule],
|
imports: [RedisMutexModule, AuthModule],
|
||||||
providers: [PasswordConverter],
|
providers: [PasswordConverter],
|
||||||
|
@ -13,9 +13,9 @@ export class ApplicationException extends Error {
|
|||||||
this.error = message.error;
|
this.error = message.error;
|
||||||
this.message = message.message as any;
|
this.message = message.message as any;
|
||||||
} else if (typeof message === 'string') {
|
} else if (typeof message === 'string') {
|
||||||
super(message as unknown as any);
|
super((message as unknown) as any);
|
||||||
} else {
|
} else {
|
||||||
super(message as unknown as any);
|
super((message as unknown) as any);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -19,16 +19,12 @@ export class HttpExceptionFilter implements ExceptionFilter {
|
|||||||
case 'graphql': {
|
case 'graphql': {
|
||||||
const errorName = exception.message;
|
const errorName = exception.message;
|
||||||
const extensions: Record<string, any> = {};
|
const extensions: Record<string, any> = {};
|
||||||
const err = exception.getResponse() as any;
|
const err = exception.getResponse();
|
||||||
if (typeof err === 'string') {
|
if (typeof err === 'string') {
|
||||||
extensions.message = err;
|
extensions.message = err;
|
||||||
} else {
|
} else {
|
||||||
Object.assign(extensions, err.extension);
|
Object.assign(extensions, (err as any).extension);
|
||||||
if (typeof err.message === 'string') {
|
extensions.message = (err as any).message;
|
||||||
extensions.message = err.message;
|
|
||||||
} else {
|
|
||||||
extensions.message = err.error;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
extensions.error = errorName;
|
extensions.error = errorName;
|
||||||
this.logger.error(extensions);
|
this.logger.error(extensions);
|
||||||
|
@ -126,7 +126,6 @@ export class BaseDbService<Entity extends AppBaseEntity> extends TypeormHelper {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
||||||
async canYouRemoveWithIds(ids: string[]): Promise<void> {
|
async canYouRemoveWithIds(ids: string[]): Promise<void> {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -1,11 +0,0 @@
|
|||||||
import { Configuration } from './entities/configuration.entity';
|
|
||||||
import { TypeOrmModule } from '@nestjs/typeorm';
|
|
||||||
import { Module } from '@nestjs/common';
|
|
||||||
import { ConfigurationsService } from './configurations.service';
|
|
||||||
import { ConfigurationsResolver } from './configurations.resolver';
|
|
||||||
|
|
||||||
@Module({
|
|
||||||
imports: [TypeOrmModule.forFeature([Configuration])],
|
|
||||||
providers: [ConfigurationsResolver, ConfigurationsService],
|
|
||||||
})
|
|
||||||
export class ConfigurationsModule {}
|
|
@ -1,30 +0,0 @@
|
|||||||
import { JwtService } from '@nestjs-lib/auth';
|
|
||||||
import { Test, TestingModule } from '@nestjs/testing';
|
|
||||||
import { ConfigurationsResolver } from './configurations.resolver';
|
|
||||||
import { ConfigurationsService } from './configurations.service';
|
|
||||||
|
|
||||||
describe('ConfigurationsResolver', () => {
|
|
||||||
let resolver: ConfigurationsResolver;
|
|
||||||
|
|
||||||
beforeEach(async () => {
|
|
||||||
const module: TestingModule = await Test.createTestingModule({
|
|
||||||
providers: [
|
|
||||||
ConfigurationsResolver,
|
|
||||||
{
|
|
||||||
provide: ConfigurationsService,
|
|
||||||
useValue: {},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
provide: JwtService,
|
|
||||||
useValue: {},
|
|
||||||
},
|
|
||||||
],
|
|
||||||
}).compile();
|
|
||||||
|
|
||||||
resolver = module.get<ConfigurationsResolver>(ConfigurationsResolver);
|
|
||||||
});
|
|
||||||
|
|
||||||
it('should be defined', () => {
|
|
||||||
expect(resolver).toBeDefined();
|
|
||||||
});
|
|
||||||
});
|
|
@ -1,39 +0,0 @@
|
|||||||
import { UnprocessableEntityException } from '@nestjs/common';
|
|
||||||
import { GetConfigurationArgs } from './dto/get-configuration.args';
|
|
||||||
import { SetConfigurationInput } from './dto/set-configuration.input';
|
|
||||||
import { Resolver, Mutation, Args, Query } from '@nestjs/graphql';
|
|
||||||
import { ConfigurationsService } from './configurations.service';
|
|
||||||
import { Configuration } from './entities/configuration.entity';
|
|
||||||
import { any, pipe, values } from 'ramda';
|
|
||||||
import { AccountRole, Roles } from '@nestjs-lib/auth';
|
|
||||||
|
|
||||||
@Roles(AccountRole.admin, AccountRole.super)
|
|
||||||
@Resolver(() => Configuration)
|
|
||||||
export class ConfigurationsResolver {
|
|
||||||
constructor(private readonly configurationsService: ConfigurationsService) {}
|
|
||||||
|
|
||||||
@Mutation(() => Configuration)
|
|
||||||
setConfiguration(
|
|
||||||
@Args('setConfigurationInput', { type: () => SetConfigurationInput })
|
|
||||||
setConfigurationInput: SetConfigurationInput,
|
|
||||||
) {
|
|
||||||
return this.configurationsService.setConfiguration(setConfigurationInput);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Query(() => Configuration, { nullable: true })
|
|
||||||
getConfiguration(
|
|
||||||
@Args()
|
|
||||||
getConfigurationArgs: GetConfigurationArgs,
|
|
||||||
) {
|
|
||||||
if (
|
|
||||||
pipe(
|
|
||||||
values,
|
|
||||||
any((value) => !value),
|
|
||||||
)(getConfigurationArgs)
|
|
||||||
) {
|
|
||||||
throw new UnprocessableEntityException('Must pass a parameter');
|
|
||||||
}
|
|
||||||
|
|
||||||
return this.configurationsService.findOneByConditions(getConfigurationArgs);
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,49 +0,0 @@
|
|||||||
import { getRepositoryToken } from '@nestjs/typeorm';
|
|
||||||
import { Test, TestingModule } from '@nestjs/testing';
|
|
||||||
import { ConfigurationsService } from './configurations.service';
|
|
||||||
import { Configuration } from './entities/configuration.entity';
|
|
||||||
import { IsNull } from 'typeorm';
|
|
||||||
import { Etcd3 } from 'etcd3';
|
|
||||||
|
|
||||||
describe('ConfigurationsService', () => {
|
|
||||||
let service: ConfigurationsService;
|
|
||||||
|
|
||||||
beforeEach(async () => {
|
|
||||||
const module: TestingModule = await Test.createTestingModule({
|
|
||||||
providers: [
|
|
||||||
ConfigurationsService,
|
|
||||||
{
|
|
||||||
provide: getRepositoryToken(Configuration),
|
|
||||||
useValue: {},
|
|
||||||
},
|
|
||||||
{
|
|
||||||
provide: Etcd3,
|
|
||||||
useValue: {},
|
|
||||||
},
|
|
||||||
],
|
|
||||||
}).compile();
|
|
||||||
|
|
||||||
service = module.get<ConfigurationsService>(ConfigurationsService);
|
|
||||||
});
|
|
||||||
|
|
||||||
it('should be defined', () => {
|
|
||||||
expect(service).toBeDefined();
|
|
||||||
});
|
|
||||||
|
|
||||||
describe('findOneByConditions', () => {
|
|
||||||
it('should select by projectId only', async () => {
|
|
||||||
const entity = new Configuration();
|
|
||||||
const findOne = jest.fn<any, [any]>(() => Promise.resolve(entity));
|
|
||||||
service['repository'].findOne = findOne;
|
|
||||||
|
|
||||||
await expect(
|
|
||||||
service.findOneByConditions({ projectId: 'uuid' }),
|
|
||||||
).resolves.toEqual(entity);
|
|
||||||
|
|
||||||
expect(findOne.mock.calls[0][0]).toMatchObject({
|
|
||||||
projectId: 'uuid',
|
|
||||||
pipelineId: IsNull(),
|
|
||||||
});
|
|
||||||
});
|
|
||||||
});
|
|
||||||
});
|
|
@ -1,55 +0,0 @@
|
|||||||
import { GetConfigurationArgs } from './dto/get-configuration.args';
|
|
||||||
import { BaseDbService } from './../commons/services/base-db.service';
|
|
||||||
import { Injectable } from '@nestjs/common';
|
|
||||||
import { Configuration } from './entities/configuration.entity';
|
|
||||||
import { InjectRepository } from '@nestjs/typeorm';
|
|
||||||
import { FindConditions, IsNull, Repository } from 'typeorm';
|
|
||||||
import { SetConfigurationInput } from './dto/set-configuration.input';
|
|
||||||
import { pick } from 'ramda';
|
|
||||||
import { Etcd3 } from 'etcd3';
|
|
||||||
|
|
||||||
@Injectable()
|
|
||||||
export class ConfigurationsService extends BaseDbService<Configuration> {
|
|
||||||
constructor(
|
|
||||||
@InjectRepository(Configuration)
|
|
||||||
configurationRepository: Repository<Configuration>,
|
|
||||||
private readonly etcd: Etcd3,
|
|
||||||
) {
|
|
||||||
super(configurationRepository);
|
|
||||||
}
|
|
||||||
|
|
||||||
async setConfiguration(dto: SetConfigurationInput) {
|
|
||||||
let entity = await this.repository.findOne(
|
|
||||||
pick(['pipelineId', 'projectId'], dto),
|
|
||||||
);
|
|
||||||
if (!entity) {
|
|
||||||
entity = this.repository.create(dto);
|
|
||||||
}
|
|
||||||
entity = await this.repository.save(entity);
|
|
||||||
await this.syncToEtcd(entity);
|
|
||||||
return entity;
|
|
||||||
}
|
|
||||||
|
|
||||||
async findOneByConditions(dto: FindConditions<GetConfigurationArgs>) {
|
|
||||||
if (dto.projectId && !dto.pipelineId) {
|
|
||||||
dto.pipelineId = IsNull();
|
|
||||||
}
|
|
||||||
return await this.repository.findOne(dto);
|
|
||||||
}
|
|
||||||
|
|
||||||
async syncToEtcd({ pipelineId, id }: { pipelineId?: string; id?: string }) {
|
|
||||||
const config = await this.repository.findOneOrFail({
|
|
||||||
where: { pipelineId, id },
|
|
||||||
relations: ['pipeline', 'project'],
|
|
||||||
});
|
|
||||||
|
|
||||||
await this.etcd
|
|
||||||
.put(`share/config/${config.id}`)
|
|
||||||
.value(config.content)
|
|
||||||
.exec();
|
|
||||||
await this.etcd
|
|
||||||
.put(`share/config/${config.pipeline.environment}/${config.project.name}`)
|
|
||||||
.value(config.content)
|
|
||||||
.exec();
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,17 +0,0 @@
|
|||||||
import { ArgsType } from '@nestjs/graphql';
|
|
||||||
import { IsUUID, IsOptional } from 'class-validator';
|
|
||||||
|
|
||||||
@ArgsType()
|
|
||||||
export class GetConfigurationArgs {
|
|
||||||
@IsUUID()
|
|
||||||
@IsOptional()
|
|
||||||
pipelineId?: string;
|
|
||||||
|
|
||||||
@IsUUID()
|
|
||||||
@IsOptional()
|
|
||||||
projectId?: string;
|
|
||||||
|
|
||||||
@IsUUID()
|
|
||||||
@IsOptional()
|
|
||||||
id?: string;
|
|
||||||
}
|
|
@ -1,26 +0,0 @@
|
|||||||
import { ConfigurationLanguage } from './../enums/configuration-language.enum';
|
|
||||||
import { IsEnum, IsString, IsUUID, Length, IsOptional } from 'class-validator';
|
|
||||||
import { InputType } from '@nestjs/graphql';
|
|
||||||
|
|
||||||
@InputType()
|
|
||||||
export class SetConfigurationInput {
|
|
||||||
@IsOptional()
|
|
||||||
@IsUUID()
|
|
||||||
id?: string;
|
|
||||||
|
|
||||||
@IsUUID()
|
|
||||||
pipelineId: string;
|
|
||||||
|
|
||||||
@IsUUID()
|
|
||||||
projectId: string;
|
|
||||||
|
|
||||||
@IsString()
|
|
||||||
content: string;
|
|
||||||
|
|
||||||
@IsEnum(ConfigurationLanguage)
|
|
||||||
language: ConfigurationLanguage;
|
|
||||||
|
|
||||||
@Length(0, 100)
|
|
||||||
@IsOptional()
|
|
||||||
name = 'Default Configuration';
|
|
||||||
}
|
|
@ -1,35 +0,0 @@
|
|||||||
import { Project } from './../../projects/project.entity';
|
|
||||||
import { ConfigurationLanguage } from './../enums/configuration-language.enum';
|
|
||||||
import { Pipeline } from './../../pipelines/pipeline.entity';
|
|
||||||
import { AppBaseEntity } from './../../commons/entities/app-base-entity';
|
|
||||||
import { ObjectType } from '@nestjs/graphql';
|
|
||||||
import { Column, Entity, ManyToOne } from 'typeorm';
|
|
||||||
|
|
||||||
@Entity()
|
|
||||||
@ObjectType()
|
|
||||||
export class Configuration extends AppBaseEntity {
|
|
||||||
@ManyToOne(() => Pipeline)
|
|
||||||
pipeline: Pipeline;
|
|
||||||
|
|
||||||
@Column({ unique: true, nullable: true })
|
|
||||||
pipelineId: string;
|
|
||||||
|
|
||||||
@ManyToOne(() => Project)
|
|
||||||
project: Project;
|
|
||||||
|
|
||||||
@Column()
|
|
||||||
projectId: string;
|
|
||||||
|
|
||||||
@Column({ comment: 'language defined in type field.' })
|
|
||||||
content: string;
|
|
||||||
|
|
||||||
@Column({ comment: '配置名称' })
|
|
||||||
name: string;
|
|
||||||
|
|
||||||
@Column({
|
|
||||||
type: 'enum',
|
|
||||||
enum: ConfigurationLanguage,
|
|
||||||
comment: 'configuration content language',
|
|
||||||
})
|
|
||||||
language: ConfigurationLanguage;
|
|
||||||
}
|
|
@ -1,10 +0,0 @@
|
|||||||
import { registerEnumType } from '@nestjs/graphql';
|
|
||||||
|
|
||||||
export enum ConfigurationLanguage {
|
|
||||||
JavaScript = 'JavaScript',
|
|
||||||
YAML = 'YAML',
|
|
||||||
}
|
|
||||||
|
|
||||||
registerEnumType(ConfigurationLanguage, {
|
|
||||||
name: 'ConfigurationLanguage',
|
|
||||||
});
|
|
@ -5,7 +5,6 @@ import { NestFactory } from '@nestjs/core';
|
|||||||
import { AppModule } from './app.module';
|
import { AppModule } from './app.module';
|
||||||
import { HttpExceptionFilter } from './commons/filters/all.exception-filter';
|
import { HttpExceptionFilter } from './commons/filters/all.exception-filter';
|
||||||
import { SanitizePipe } from './commons/pipes/sanitize.pipe';
|
import { SanitizePipe } from './commons/pipes/sanitize.pipe';
|
||||||
import { ServiceRegister } from 'configuration';
|
|
||||||
|
|
||||||
async function bootstrap() {
|
async function bootstrap() {
|
||||||
const app = await NestFactory.create(AppModule, { bodyParser: false });
|
const app = await NestFactory.create(AppModule, { bodyParser: false });
|
||||||
@ -18,10 +17,6 @@ async function bootstrap() {
|
|||||||
);
|
);
|
||||||
const httpExceptionFilterLogger = await app.resolve(PinoLogger);
|
const httpExceptionFilterLogger = await app.resolve(PinoLogger);
|
||||||
app.useGlobalFilters(new HttpExceptionFilter(httpExceptionFilterLogger));
|
app.useGlobalFilters(new HttpExceptionFilter(httpExceptionFilterLogger));
|
||||||
const server = await app.listen(configService.get<number>('http.port', 0));
|
await app.listen(configService.get<number>('http.port'));
|
||||||
const port = server.address().port;
|
|
||||||
const register = new ServiceRegister({ etcd: { hosts: 'http://rpi:2379' } });
|
|
||||||
register.register('fennec/api', `http://localhost:${port}`);
|
|
||||||
register.register('api.fennec', `http://localhost:${port}`);
|
|
||||||
}
|
}
|
||||||
bootstrap();
|
bootstrap();
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { InputType } from '@nestjs/graphql';
|
import { Field, InputType } from '@nestjs/graphql';
|
||||||
import { PipelineUnits } from '../enums/pipeline-units.enum';
|
import { PipelineUnits } from '../enums/pipeline-units.enum';
|
||||||
|
|
||||||
@InputType()
|
@InputType()
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import { Field, InputType, Int, ObjectType } from '@nestjs/graphql';
|
import { Field, InputType, Int, ObjectType } from '@nestjs/graphql';
|
||||||
import { Type } from 'class-transformer';
|
import { Type } from 'class-transformer';
|
||||||
import { IsInstance, ValidateNested } from 'class-validator';
|
import { IsInstance, isInstance, ValidateNested } from 'class-validator';
|
||||||
import { WorkUnit } from './work-unit.model';
|
import { WorkUnit } from './work-unit.model';
|
||||||
|
|
||||||
@InputType('WorkUnitMetadataInput')
|
@InputType('WorkUnitMetadataInput')
|
||||||
|
@ -16,10 +16,12 @@ import {
|
|||||||
} from './pipeline-tasks.constants';
|
} from './pipeline-tasks.constants';
|
||||||
import { PipelineTaskLogger } from './pipeline-task.logger';
|
import { PipelineTaskLogger } from './pipeline-task.logger';
|
||||||
import { PipelineTaskFlushService } from './pipeline-task-flush.service';
|
import { PipelineTaskFlushService } from './pipeline-task-flush.service';
|
||||||
|
import { CommonsModule } from '../commons/commons.module';
|
||||||
import { DeployByPm2Service } from './runners/deploy-by-pm2/deploy-by-pm2.service';
|
import { DeployByPm2Service } from './runners/deploy-by-pm2/deploy-by-pm2.service';
|
||||||
|
|
||||||
@Module({
|
@Module({
|
||||||
imports: [
|
imports: [
|
||||||
|
CommonsModule,
|
||||||
TypeOrmModule.forFeature([PipelineTask, Pipeline]),
|
TypeOrmModule.forFeature([PipelineTask, Pipeline]),
|
||||||
RedisModule,
|
RedisModule,
|
||||||
ReposModule,
|
ReposModule,
|
||||||
|
@ -35,6 +35,15 @@ export class PipelineTasksResolver {
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Subscription(() => PipelineTask, {
|
||||||
|
resolve: (value) => {
|
||||||
|
return value;
|
||||||
|
},
|
||||||
|
})
|
||||||
|
async pipelineTaskChanged(@Args('id') id: string) {
|
||||||
|
// return await this.service.watchTaskUpdated(id);
|
||||||
|
}
|
||||||
|
|
||||||
@Query(() => [PipelineTask])
|
@Query(() => [PipelineTask])
|
||||||
async listPipelineTaskByPipelineId(@Args('pipelineId') pipelineId: string) {
|
async listPipelineTaskByPipelineId(@Args('pipelineId') pipelineId: string) {
|
||||||
return await this.service.listTasksByPipelineId(pipelineId);
|
return await this.service.listTasksByPipelineId(pipelineId);
|
||||||
|
@ -12,6 +12,7 @@ describe('PipelineTasksService', () => {
|
|||||||
let service: PipelineTasksService;
|
let service: PipelineTasksService;
|
||||||
let module: TestingModule;
|
let module: TestingModule;
|
||||||
let taskRepository: Repository<PipelineTask>;
|
let taskRepository: Repository<PipelineTask>;
|
||||||
|
let pipelineRepository: Repository<Pipeline>;
|
||||||
|
|
||||||
beforeEach(async () => {
|
beforeEach(async () => {
|
||||||
module = await Test.createTestingModule({
|
module = await Test.createTestingModule({
|
||||||
@ -42,6 +43,7 @@ describe('PipelineTasksService', () => {
|
|||||||
|
|
||||||
service = module.get<PipelineTasksService>(PipelineTasksService);
|
service = module.get<PipelineTasksService>(PipelineTasksService);
|
||||||
taskRepository = module.get(getRepositoryToken(PipelineTask));
|
taskRepository = module.get(getRepositoryToken(PipelineTask));
|
||||||
|
pipelineRepository = module.get(getRepositoryToken(Pipeline));
|
||||||
jest
|
jest
|
||||||
.spyOn(taskRepository, 'save')
|
.spyOn(taskRepository, 'save')
|
||||||
.mockImplementation(async (data: any) => data);
|
.mockImplementation(async (data: any) => data);
|
||||||
|
@ -4,6 +4,7 @@ import { PipelineTask } from './pipeline-task.entity';
|
|||||||
import { Repository } from 'typeorm';
|
import { Repository } from 'typeorm';
|
||||||
import { CreatePipelineTaskInput } from './dtos/create-pipeline-task.input';
|
import { CreatePipelineTaskInput } from './dtos/create-pipeline-task.input';
|
||||||
import { Pipeline } from '../pipelines/pipeline.entity';
|
import { Pipeline } from '../pipelines/pipeline.entity';
|
||||||
|
import debug from 'debug';
|
||||||
import { AmqpConnection, RabbitRPC } from '@golevelup/nestjs-rabbitmq';
|
import { AmqpConnection, RabbitRPC } from '@golevelup/nestjs-rabbitmq';
|
||||||
import {
|
import {
|
||||||
EXCHANGE_PIPELINE_TASK_TOPIC,
|
EXCHANGE_PIPELINE_TASK_TOPIC,
|
||||||
@ -18,6 +19,8 @@ import { InjectPinoLogger, PinoLogger } from 'nestjs-pino';
|
|||||||
import { getAppInstanceRouteKey } from '../commons/utils/rabbit-mq';
|
import { getAppInstanceRouteKey } from '../commons/utils/rabbit-mq';
|
||||||
import { ROUTE_PIPELINE_TASK_KILL } from './pipeline-tasks.constants';
|
import { ROUTE_PIPELINE_TASK_KILL } from './pipeline-tasks.constants';
|
||||||
|
|
||||||
|
const log = debug('fennec:pipeline-tasks:service');
|
||||||
|
|
||||||
@Injectable()
|
@Injectable()
|
||||||
export class PipelineTasksService {
|
export class PipelineTasksService {
|
||||||
constructor(
|
constructor(
|
||||||
|
@ -28,8 +28,4 @@ export class CreatePipelineInput {
|
|||||||
@ValidateNested()
|
@ValidateNested()
|
||||||
@IsInstance(WorkUnitMetadata)
|
@IsInstance(WorkUnitMetadata)
|
||||||
workUnitMetadata: WorkUnitMetadata;
|
workUnitMetadata: WorkUnitMetadata;
|
||||||
|
|
||||||
@IsString()
|
|
||||||
@MaxLength(100)
|
|
||||||
environment: string;
|
|
||||||
}
|
}
|
||||||
|
@ -12,7 +12,7 @@ export class Pipeline extends AppBaseEntity {
|
|||||||
@Column()
|
@Column()
|
||||||
projectId: string;
|
projectId: string;
|
||||||
|
|
||||||
@Column({ comment: 'E.g., remotes/origin/master' })
|
@Column({ comment: 'eg: remotes/origin/master' })
|
||||||
branch: string;
|
branch: string;
|
||||||
|
|
||||||
@Column()
|
@Column()
|
||||||
@ -20,7 +20,4 @@ export class Pipeline extends AppBaseEntity {
|
|||||||
|
|
||||||
@Column({ type: 'jsonb' })
|
@Column({ type: 'jsonb' })
|
||||||
workUnitMetadata: WorkUnitMetadata;
|
workUnitMetadata: WorkUnitMetadata;
|
||||||
|
|
||||||
@Column()
|
|
||||||
environment: string;
|
|
||||||
}
|
}
|
||||||
|
@ -5,11 +5,14 @@ import { TypeOrmModule } from '@nestjs/typeorm';
|
|||||||
import { Pipeline } from './pipeline.entity';
|
import { Pipeline } from './pipeline.entity';
|
||||||
import { CommitLogsResolver } from './commit-logs.resolver';
|
import { CommitLogsResolver } from './commit-logs.resolver';
|
||||||
import { PipelineTasksModule } from '../pipeline-tasks/pipeline-tasks.module';
|
import { PipelineTasksModule } from '../pipeline-tasks/pipeline-tasks.module';
|
||||||
|
import { ReposModule } from '../repos/repos.module';
|
||||||
import { RabbitMQModule } from '@golevelup/nestjs-rabbitmq';
|
import { RabbitMQModule } from '@golevelup/nestjs-rabbitmq';
|
||||||
import { ConfigModule, ConfigService } from '@nestjs/config';
|
import { ConfigModule, ConfigService } from '@nestjs/config';
|
||||||
|
import { CommonsModule } from '../commons/commons.module';
|
||||||
|
|
||||||
@Module({
|
@Module({
|
||||||
imports: [
|
imports: [
|
||||||
|
CommonsModule,
|
||||||
TypeOrmModule.forFeature([Pipeline]),
|
TypeOrmModule.forFeature([Pipeline]),
|
||||||
PipelineTasksModule,
|
PipelineTasksModule,
|
||||||
RabbitMQModule.forRootAsync(RabbitMQModule, {
|
RabbitMQModule.forRootAsync(RabbitMQModule, {
|
||||||
|
@ -2,11 +2,13 @@ import { Test, TestingModule } from '@nestjs/testing';
|
|||||||
import { PipelinesService } from './pipelines.service';
|
import { PipelinesService } from './pipelines.service';
|
||||||
import { Pipeline } from './pipeline.entity';
|
import { Pipeline } from './pipeline.entity';
|
||||||
import { getRepositoryToken } from '@nestjs/typeorm';
|
import { getRepositoryToken } from '@nestjs/typeorm';
|
||||||
|
import { Repository } from 'typeorm';
|
||||||
import { Project } from '../projects/project.entity';
|
import { Project } from '../projects/project.entity';
|
||||||
import { AmqpConnection } from '@golevelup/nestjs-rabbitmq';
|
import { AmqpConnection } from '@golevelup/nestjs-rabbitmq';
|
||||||
|
|
||||||
describe('PipelinesService', () => {
|
describe('PipelinesService', () => {
|
||||||
let service: PipelinesService;
|
let service: PipelinesService;
|
||||||
|
let repository: Repository<Pipeline>;
|
||||||
let pipeline: Pipeline;
|
let pipeline: Pipeline;
|
||||||
|
|
||||||
beforeEach(async () => {
|
beforeEach(async () => {
|
||||||
@ -38,6 +40,7 @@ describe('PipelinesService', () => {
|
|||||||
}).compile();
|
}).compile();
|
||||||
|
|
||||||
service = module.get<PipelinesService>(PipelinesService);
|
service = module.get<PipelinesService>(PipelinesService);
|
||||||
|
repository = module.get(getRepositoryToken(Pipeline));
|
||||||
});
|
});
|
||||||
|
|
||||||
it('should be defined', () => {
|
it('should be defined', () => {
|
||||||
|
@ -19,9 +19,7 @@ import { plainToClass } from 'class-transformer';
|
|||||||
|
|
||||||
@Injectable()
|
@Injectable()
|
||||||
export class PipelinesService extends BaseDbService<Pipeline> {
|
export class PipelinesService extends BaseDbService<Pipeline> {
|
||||||
readonly uniqueFields: Array<Array<keyof Pipeline>> = [
|
readonly uniqueFields: Array<Array<keyof Pipeline>> = [['projectId', 'name']];
|
||||||
['projectId', 'name', 'environment'],
|
|
||||||
];
|
|
||||||
constructor(
|
constructor(
|
||||||
@InjectRepository(Pipeline)
|
@InjectRepository(Pipeline)
|
||||||
readonly repository: Repository<Pipeline>,
|
readonly repository: Repository<Pipeline>,
|
||||||
|
@ -1,5 +1,5 @@
|
|||||||
import { ObjectType } from '@nestjs/graphql';
|
import { ObjectType } from '@nestjs/graphql';
|
||||||
import { Entity, Column } from 'typeorm';
|
import { Entity, Column, DeleteDateColumn } from 'typeorm';
|
||||||
import { AppBaseEntity } from '../commons/entities/app-base-entity';
|
import { AppBaseEntity } from '../commons/entities/app-base-entity';
|
||||||
|
|
||||||
@ObjectType()
|
@ObjectType()
|
||||||
|
@ -6,9 +6,11 @@ import { Project } from './project.entity';
|
|||||||
import { RabbitMQModule } from '@golevelup/nestjs-rabbitmq';
|
import { RabbitMQModule } from '@golevelup/nestjs-rabbitmq';
|
||||||
import { ConfigModule, ConfigService } from '@nestjs/config';
|
import { ConfigModule, ConfigService } from '@nestjs/config';
|
||||||
import { EXCHANGE_PROJECT_FANOUT } from './projects.constants';
|
import { EXCHANGE_PROJECT_FANOUT } from './projects.constants';
|
||||||
|
import { CommonsModule } from '../commons/commons.module';
|
||||||
|
|
||||||
@Module({
|
@Module({
|
||||||
imports: [
|
imports: [
|
||||||
|
CommonsModule,
|
||||||
TypeOrmModule.forFeature([Project]),
|
TypeOrmModule.forFeature([Project]),
|
||||||
RabbitMQModule.forRootAsync(RabbitMQModule, {
|
RabbitMQModule.forRootAsync(RabbitMQModule, {
|
||||||
imports: [ConfigModule],
|
imports: [ConfigModule],
|
||||||
|
@ -1,5 +1,10 @@
|
|||||||
import { ObjectType, Field } from '@nestjs/graphql';
|
import { ObjectType, Field } from '@nestjs/graphql';
|
||||||
import { BranchSummaryBranch } from 'simple-git';
|
import {
|
||||||
|
LogResult,
|
||||||
|
DefaultLogFields,
|
||||||
|
BranchSummary,
|
||||||
|
BranchSummaryBranch,
|
||||||
|
} from 'simple-git';
|
||||||
|
|
||||||
@ObjectType()
|
@ObjectType()
|
||||||
export class Branch implements BranchSummaryBranch {
|
export class Branch implements BranchSummaryBranch {
|
||||||
|
@ -7,12 +7,14 @@ import { ConfigModule, ConfigService } from '@nestjs/config';
|
|||||||
import { ProjectsModule } from '../projects/projects.module';
|
import { ProjectsModule } from '../projects/projects.module';
|
||||||
import { EXCHANGE_REPO } from './repos.constants';
|
import { EXCHANGE_REPO } from './repos.constants';
|
||||||
import { RabbitMQModule } from '@golevelup/nestjs-rabbitmq';
|
import { RabbitMQModule } from '@golevelup/nestjs-rabbitmq';
|
||||||
|
import { CommonsModule } from '../commons/commons.module';
|
||||||
|
|
||||||
@Module({
|
@Module({
|
||||||
imports: [
|
imports: [
|
||||||
TypeOrmModule.forFeature([Project]),
|
TypeOrmModule.forFeature([Project]),
|
||||||
ConfigModule,
|
ConfigModule,
|
||||||
ProjectsModule,
|
ProjectsModule,
|
||||||
|
CommonsModule,
|
||||||
RabbitMQModule.forRootAsync(RabbitMQModule, {
|
RabbitMQModule.forRootAsync(RabbitMQModule, {
|
||||||
imports: [ConfigModule],
|
imports: [ConfigModule],
|
||||||
useFactory: (configService: ConfigService) => ({
|
useFactory: (configService: ConfigService) => ({
|
||||||
|
@ -161,7 +161,7 @@ describe('ReposService', () => {
|
|||||||
const project = new Project();
|
const project = new Project();
|
||||||
const pipeline = new Pipeline();
|
const pipeline = new Pipeline();
|
||||||
pipeline.branch = 'test';
|
pipeline.branch = 'test';
|
||||||
const fetch = jest.fn<any, [any]>(() => Promise.resolve());
|
const fetch = jest.fn((_: any) => Promise.resolve());
|
||||||
pipeline.project = project;
|
pipeline.project = project;
|
||||||
const getGit = jest.spyOn(service, 'getGit').mockImplementation(() =>
|
const getGit = jest.spyOn(service, 'getGit').mockImplementation(() =>
|
||||||
Promise.resolve({
|
Promise.resolve({
|
||||||
@ -182,7 +182,7 @@ describe('ReposService', () => {
|
|||||||
const project = new Project();
|
const project = new Project();
|
||||||
const pipeline = new Pipeline();
|
const pipeline = new Pipeline();
|
||||||
pipeline.branch = 'test';
|
pipeline.branch = 'test';
|
||||||
const fetch = jest.fn<any, [any]>(() => Promise.resolve());
|
const fetch = jest.fn((_: any) => Promise.resolve());
|
||||||
pipeline.project = project;
|
pipeline.project = project;
|
||||||
const getGit = jest
|
const getGit = jest
|
||||||
.spyOn(service, 'getGit')
|
.spyOn(service, 'getGit')
|
||||||
@ -196,7 +196,7 @@ describe('ReposService', () => {
|
|||||||
const project = new Project();
|
const project = new Project();
|
||||||
const pipeline = new Pipeline();
|
const pipeline = new Pipeline();
|
||||||
pipeline.branch = 'test';
|
pipeline.branch = 'test';
|
||||||
const fetch = jest.fn<any, [any]>(() => Promise.reject('error'));
|
const fetch = jest.fn((_: any) => Promise.reject('error'));
|
||||||
pipeline.project = project;
|
pipeline.project = project;
|
||||||
const getGit = jest.spyOn(service, 'getGit').mockImplementation(() =>
|
const getGit = jest.spyOn(service, 'getGit').mockImplementation(() =>
|
||||||
Promise.resolve({
|
Promise.resolve({
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
import { Module } from '@nestjs/common';
|
import { MiddlewareConsumer, Module } from '@nestjs/common';
|
||||||
import { TypeOrmModule } from '@nestjs/typeorm';
|
import { TypeOrmModule } from '@nestjs/typeorm';
|
||||||
import { PipelineTasksModule } from '../pipeline-tasks/pipeline-tasks.module';
|
import { PipelineTasksModule } from '../pipeline-tasks/pipeline-tasks.module';
|
||||||
import { GiteaWebhooksController } from './gitea-webhooks.controller';
|
import { GiteaWebhooksController } from './gitea-webhooks.controller';
|
||||||
@ -10,4 +10,5 @@ import { WebhooksService } from './webhooks.service';
|
|||||||
controllers: [GiteaWebhooksController],
|
controllers: [GiteaWebhooksController],
|
||||||
providers: [WebhooksService],
|
providers: [WebhooksService],
|
||||||
})
|
})
|
||||||
export class WebhooksModule {}
|
export class WebhooksModule {
|
||||||
|
}
|
||||||
|
@ -10,6 +10,7 @@
|
|||||||
"lib": ["ES2021"],
|
"lib": ["ES2021"],
|
||||||
"sourceMap": true,
|
"sourceMap": true,
|
||||||
"outDir": "./dist",
|
"outDir": "./dist",
|
||||||
|
"rootDir": "./src",
|
||||||
"baseUrl": "./",
|
"baseUrl": "./",
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user