mirror of
https://github.com/standardnotes/server
synced 2026-01-17 23:04:34 -05:00
Compare commits
9 Commits
@standardn
...
@standardn
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b0b3c6671d | ||
|
|
6ddb8fb6c2 | ||
|
|
66da49b0df | ||
|
|
750cd26c36 | ||
|
|
4c15589663 | ||
|
|
62a0e89748 | ||
|
|
b9603240d0 | ||
|
|
85d87bb45e | ||
|
|
3193308d8d |
@@ -7,6 +7,7 @@ DB_PORT=3306
|
||||
DB_USERNAME=std_notes_user
|
||||
DB_PASSWORD=changeme123
|
||||
DB_DATABASE=standard_notes_db
|
||||
DB_TYPE=mysql
|
||||
|
||||
#########
|
||||
# CACHE #
|
||||
|
||||
7
.github/workflows/common-docker-image.yml
vendored
7
.github/workflows/common-docker-image.yml
vendored
@@ -29,6 +29,10 @@ jobs:
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: '3.11'
|
||||
|
||||
- name: Create Bundle Dir
|
||||
id: bundle-dir
|
||||
run: echo "temp_dir=$(mktemp -d -t ${{ inputs.service_name }}-${{ github.sha }}-XXXXXXX)" >> $GITHUB_OUTPUT
|
||||
@@ -48,6 +52,9 @@ jobs:
|
||||
registry-url: 'https://registry.npmjs.org'
|
||||
node-version-file: '.nvmrc'
|
||||
|
||||
- name: Install dependencies
|
||||
run: yarn install --immutable
|
||||
|
||||
- name: Build
|
||||
if: steps.cache-build.outputs.cache-hit != 'true'
|
||||
run: yarn build ${{ inputs.package_path }}
|
||||
|
||||
BIN
.yarn/cache/@aws-sdk-abort-controller-npm-3.329.0-330df022b1-86f90b191d.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-abort-controller-npm-3.329.0-330df022b1-86f90b191d.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-config-resolver-npm-3.329.0-ad937b6b5a-96a66188db.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-config-resolver-npm-3.329.0-ad937b6b5a-96a66188db.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-credential-provider-env-npm-3.329.0-a157793370-f55a57adfb.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-credential-provider-env-npm-3.329.0-a157793370-f55a57adfb.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-credential-provider-imds-npm-3.329.0-04ff9ca00d-6ec90ae7e4.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-credential-provider-imds-npm-3.329.0-04ff9ca00d-6ec90ae7e4.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-credential-provider-process-npm-3.329.0-a4e22c58e7-ad125b9c5e.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-credential-provider-process-npm-3.329.0-a4e22c58e7-ad125b9c5e.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-credential-provider-web-identity-npm-3.329.0-64a1517f92-cfdf8074d2.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-credential-provider-web-identity-npm-3.329.0-64a1517f92-cfdf8074d2.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-fetch-http-handler-npm-3.329.0-2d5e8249a0-d0961fb2ed.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-fetch-http-handler-npm-3.329.0-2d5e8249a0-d0961fb2ed.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-hash-node-npm-3.329.0-a7c67f51ba-7eaa0387ec.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-hash-node-npm-3.329.0-a7c67f51ba-7eaa0387ec.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-invalid-dependency-npm-3.329.0-09565fa8f1-d81664bb97.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-invalid-dependency-npm-3.329.0-09565fa8f1-d81664bb97.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-md5-js-npm-3.329.0-62455ff652-3157a9019d.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-md5-js-npm-3.329.0-62455ff652-3157a9019d.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-content-length-npm-3.329.0-572714587f-b6e8b7d79a.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-content-length-npm-3.329.0-572714587f-b6e8b7d79a.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-endpoint-npm-3.329.0-0500d0a5da-407dd4e705.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-endpoint-npm-3.329.0-0500d0a5da-407dd4e705.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-host-header-npm-3.329.0-e3a2c4eb17-f0470b64e8.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-host-header-npm-3.329.0-e3a2c4eb17-f0470b64e8.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-logger-npm-3.329.0-a83672165b-b8b4732902.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-logger-npm-3.329.0-a83672165b-b8b4732902.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-recursion-detection-npm-3.329.0-9530d1707a-7dff5457a7.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-recursion-detection-npm-3.329.0-9530d1707a-7dff5457a7.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-retry-npm-3.329.0-f85eca00a2-9d66667c56.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-retry-npm-3.329.0-f85eca00a2-9d66667c56.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-sdk-sqs-npm-3.329.0-53e6711cf6-9d1e875bfb.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-sdk-sqs-npm-3.329.0-53e6711cf6-9d1e875bfb.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-sdk-sts-npm-3.329.0-b8e0612c39-845b3f43bb.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-sdk-sts-npm-3.329.0-b8e0612c39-845b3f43bb.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-serde-npm-3.329.0-70b1cb397b-d200e91340.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-serde-npm-3.329.0-70b1cb397b-d200e91340.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-signing-npm-3.329.0-fafebbac45-06103d8a7d.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-signing-npm-3.329.0-fafebbac45-06103d8a7d.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-stack-npm-3.329.0-deb18647d9-80f34d8ff6.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-stack-npm-3.329.0-deb18647d9-80f34d8ff6.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-middleware-user-agent-npm-3.332.0-477b2b503f-75bfe862c1.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-middleware-user-agent-npm-3.332.0-477b2b503f-75bfe862c1.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-node-config-provider-npm-3.329.0-bea365bcec-2af283e3f5.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-node-config-provider-npm-3.329.0-bea365bcec-2af283e3f5.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-property-provider-npm-3.329.0-8f019ecd0f-e11809cea3.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-property-provider-npm-3.329.0-8f019ecd0f-e11809cea3.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-protocol-http-npm-3.329.0-9599f077f6-459a46d8c0.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-protocol-http-npm-3.329.0-9599f077f6-459a46d8c0.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-querystring-builder-npm-3.329.0-2df4fb67f1-681efb98ac.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-querystring-builder-npm-3.329.0-2df4fb67f1-681efb98ac.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-querystring-parser-npm-3.329.0-4b1a1e0fb5-9ed54dc61d.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-querystring-parser-npm-3.329.0-4b1a1e0fb5-9ed54dc61d.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-service-error-classification-npm-3.329.0-c85b83bd81-215b61f2cc.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-service-error-classification-npm-3.329.0-c85b83bd81-215b61f2cc.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-shared-ini-file-loader-npm-3.329.0-b4fe16c15a-4dda8a5a79.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-shared-ini-file-loader-npm-3.329.0-b4fe16c15a-4dda8a5a79.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-signature-v4-npm-3.329.0-0702b2b15c-aba37d7f61.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-signature-v4-npm-3.329.0-0702b2b15c-aba37d7f61.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-smithy-client-npm-3.329.0-7cced1d303-45f87ed846.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-smithy-client-npm-3.329.0-7cced1d303-45f87ed846.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-types-npm-3.329.0-06a5c61fa9-28aff60622.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-types-npm-3.329.0-06a5c61fa9-28aff60622.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-url-parser-npm-3.329.0-70076d0522-9ca336e5bb.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-url-parser-npm-3.329.0-70076d0522-9ca336e5bb.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-util-defaults-mode-browser-npm-3.329.0-c5d6a57d9a-ccff18607b.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-util-defaults-mode-browser-npm-3.329.0-c5d6a57d9a-ccff18607b.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-util-defaults-mode-node-npm-3.329.0-fd81099dd9-f927efbc3d.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-util-defaults-mode-node-npm-3.329.0-fd81099dd9-f927efbc3d.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-util-endpoints-npm-3.332.0-8713e2eaa5-1974420c77.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-util-endpoints-npm-3.332.0-8713e2eaa5-1974420c77.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-util-middleware-npm-3.329.0-659548e387-0493c049ae.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-util-middleware-npm-3.329.0-659548e387-0493c049ae.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-util-retry-npm-3.329.0-39c3180797-3612d19ae4.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-util-retry-npm-3.329.0-39c3180797-3612d19ae4.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-util-user-agent-browser-npm-3.329.0-14a80d95c5-04f10b65e7.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-util-user-agent-browser-npm-3.329.0-14a80d95c5-04f10b65e7.zip
vendored
Normal file
Binary file not shown.
BIN
.yarn/cache/@aws-sdk-util-user-agent-node-npm-3.329.0-178e22c724-cebebd6e4d.zip
vendored
Normal file
BIN
.yarn/cache/@aws-sdk-util-user-agent-node-npm-3.329.0-178e22c724-cebebd6e4d.zip
vendored
Normal file
Binary file not shown.
Binary file not shown.
@@ -8,7 +8,7 @@
|
||||
]
|
||||
},
|
||||
"engines": {
|
||||
"node": ">=18.0.0 <19.0.0"
|
||||
"node": ">=18.0.0 <21.0.0"
|
||||
},
|
||||
"scripts": {
|
||||
"lint": "yarn workspaces foreach -p -j 10 --verbose run lint",
|
||||
|
||||
@@ -3,6 +3,16 @@
|
||||
All notable changes to this project will be documented in this file.
|
||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||
|
||||
## [2.22.2](https://github.com/standardnotes/server/compare/@standardnotes/analytics@2.22.1...@standardnotes/analytics@2.22.2) (2023-05-15)
|
||||
|
||||
**Note:** Version bump only for package @standardnotes/analytics
|
||||
|
||||
## [2.22.1](https://github.com/standardnotes/server/compare/@standardnotes/analytics@2.22.0...@standardnotes/analytics@2.22.1) (2023-05-09)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* node engine version requirement in package.json files ([62a0e89](https://github.com/standardnotes/server/commit/62a0e89748ab306566c4aa10b9dc0385fb0f1684))
|
||||
|
||||
# [2.22.0](https://github.com/standardnotes/server/compare/@standardnotes/analytics@2.21.11...@standardnotes/analytics@2.22.0) (2023-05-08)
|
||||
|
||||
### Features
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
{
|
||||
"name": "@standardnotes/analytics",
|
||||
"version": "2.22.0",
|
||||
"version": "2.22.2",
|
||||
"engines": {
|
||||
"node": ">=18.0.0 <19.0.0"
|
||||
"node": ">=18.0.0 <21.0.0"
|
||||
},
|
||||
"private": true,
|
||||
"description": "Analytics tools for Standard Notes projects",
|
||||
@@ -40,8 +40,8 @@
|
||||
"typescript": "^5.0.4"
|
||||
},
|
||||
"dependencies": {
|
||||
"@aws-sdk/client-sns": "^3.328.0",
|
||||
"@aws-sdk/client-sqs": "^3.328.0",
|
||||
"@aws-sdk/client-sns": "^3.332.0",
|
||||
"@aws-sdk/client-sqs": "^3.332.0",
|
||||
"@newrelic/winston-enricher": "^4.0.1",
|
||||
"@standardnotes/common": "workspace:*",
|
||||
"@standardnotes/domain-core": "workspace:^",
|
||||
|
||||
@@ -3,6 +3,22 @@
|
||||
All notable changes to this project will be documented in this file.
|
||||
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
||||
|
||||
## [1.53.1](https://github.com/standardnotes/api-gateway/compare/@standardnotes/api-gateway@1.53.0...@standardnotes/api-gateway@1.53.1) (2023-05-15)
|
||||
|
||||
**Note:** Version bump only for package @standardnotes/api-gateway
|
||||
|
||||
# [1.53.0](https://github.com/standardnotes/api-gateway/compare/@standardnotes/api-gateway@1.52.1...@standardnotes/api-gateway@1.53.0) (2023-05-09)
|
||||
|
||||
### Features
|
||||
|
||||
* **home-server:** add boilerplate ([#601](https://github.com/standardnotes/api-gateway/issues/601)) ([750cd26](https://github.com/standardnotes/api-gateway/commit/750cd26c369e7d93fa3da29dbe41823059252639))
|
||||
|
||||
## [1.52.1](https://github.com/standardnotes/api-gateway/compare/@standardnotes/api-gateway@1.52.0...@standardnotes/api-gateway@1.52.1) (2023-05-09)
|
||||
|
||||
### Bug Fixes
|
||||
|
||||
* node engine version requirement in package.json files ([62a0e89](https://github.com/standardnotes/api-gateway/commit/62a0e89748ab306566c4aa10b9dc0385fb0f1684))
|
||||
|
||||
# [1.52.0](https://github.com/standardnotes/api-gateway/compare/@standardnotes/api-gateway@1.51.0...@standardnotes/api-gateway@1.52.0) (2023-05-08)
|
||||
|
||||
### Features
|
||||
|
||||
@@ -32,7 +32,7 @@ const robots = require('express-robots-txt')
|
||||
|
||||
import { InversifyExpressServer } from 'inversify-express-utils'
|
||||
import { ContainerConfigLoader } from '../src/Bootstrap/Container'
|
||||
import TYPES from '../src/Bootstrap/Types'
|
||||
import { TYPES } from '../src/Bootstrap/Types'
|
||||
import { Env } from '../src/Bootstrap/Env'
|
||||
|
||||
const container = new ContainerConfigLoader()
|
||||
|
||||
@@ -1,13 +1,17 @@
|
||||
{
|
||||
"name": "@standardnotes/api-gateway",
|
||||
"version": "1.52.0",
|
||||
"version": "1.53.1",
|
||||
"engines": {
|
||||
"node": ">=18.0.0 <19.0.0"
|
||||
"node": ">=18.0.0 <21.0.0"
|
||||
},
|
||||
"private": true,
|
||||
"description": "API Gateway For Standard Notes Services",
|
||||
"main": "dist/src/index.js",
|
||||
"typings": "dist/src/index.d.ts",
|
||||
"types": "dist/src/index.d.ts",
|
||||
"files": [
|
||||
"dist/src/**/*.js",
|
||||
"dist/src/**/*.d.ts"
|
||||
],
|
||||
"repository": "git@github.com:standardnotes/api-gateway.git",
|
||||
"author": "Karol Sójko <karolsojko@standardnotes.com>",
|
||||
"license": "AGPL-3.0-or-later",
|
||||
|
||||
@@ -7,7 +7,7 @@ import { Container } from 'inversify'
|
||||
import { Timer, TimerInterface } from '@standardnotes/time'
|
||||
|
||||
import { Env } from './Env'
|
||||
import TYPES from './Types'
|
||||
import { TYPES } from './Types'
|
||||
import { AuthMiddleware } from '../Controller/AuthMiddleware'
|
||||
import { HttpServiceInterface } from '../Service/Http/HttpServiceInterface'
|
||||
import { HttpService } from '../Service/Http/HttpService'
|
||||
@@ -42,15 +42,17 @@ export class ContainerConfigLoader {
|
||||
})
|
||||
container.bind<winston.Logger>(TYPES.Logger).toConstantValue(logger)
|
||||
|
||||
const redisUrl = env.get('REDIS_URL')
|
||||
const isRedisInClusterMode = redisUrl.indexOf(',') > 0
|
||||
let redis
|
||||
if (isRedisInClusterMode) {
|
||||
redis = new Redis.Cluster(redisUrl.split(','))
|
||||
} else {
|
||||
redis = new Redis(redisUrl)
|
||||
if (!isConfiguredForHomeServer) {
|
||||
const redisUrl = env.get('REDIS_URL')
|
||||
const isRedisInClusterMode = redisUrl.indexOf(',') > 0
|
||||
let redis
|
||||
if (isRedisInClusterMode) {
|
||||
redis = new Redis.Cluster(redisUrl.split(','))
|
||||
} else {
|
||||
redis = new Redis(redisUrl)
|
||||
}
|
||||
container.bind(TYPES.Redis).toConstantValue(redis)
|
||||
}
|
||||
container.bind(TYPES.Redis).toConstantValue(redis)
|
||||
|
||||
container.bind<AxiosInstance>(TYPES.HTTPClient).toConstantValue(axios.create())
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
const TYPES = {
|
||||
export const TYPES = {
|
||||
Logger: Symbol.for('Logger'),
|
||||
Redis: Symbol.for('Redis'),
|
||||
HTTPClient: Symbol.for('HTTPClient'),
|
||||
@@ -24,4 +24,4 @@ const TYPES = {
|
||||
Timer: Symbol.for('Timer'),
|
||||
}
|
||||
|
||||
export default TYPES
|
||||
// export default TYPES
|
||||
|
||||
3
packages/api-gateway/src/Bootstrap/index.ts
Normal file
3
packages/api-gateway/src/Bootstrap/index.ts
Normal file
@@ -0,0 +1,3 @@
|
||||
export * from './Container'
|
||||
export * from './Env'
|
||||
export * from './Types'
|
||||
@@ -8,7 +8,7 @@ import { verify } from 'jsonwebtoken'
|
||||
import { AxiosError, AxiosInstance } from 'axios'
|
||||
import { Logger } from 'winston'
|
||||
|
||||
import TYPES from '../Bootstrap/Types'
|
||||
import { TYPES } from '../Bootstrap/Types'
|
||||
import { CrossServiceTokenCacheInterface } from '../Service/Cache/CrossServiceTokenCacheInterface'
|
||||
|
||||
@injectable()
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { Request, Response } from 'express'
|
||||
import { inject } from 'inversify'
|
||||
import { controller, all, BaseHttpController, httpPost, httpGet, results, httpDelete } from 'inversify-express-utils'
|
||||
import TYPES from '../Bootstrap/Types'
|
||||
import { TYPES } from '../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('')
|
||||
|
||||
@@ -5,7 +5,7 @@ import { BaseMiddleware } from 'inversify-express-utils'
|
||||
import { verify } from 'jsonwebtoken'
|
||||
import { AxiosError, AxiosInstance, AxiosResponse } from 'axios'
|
||||
import { Logger } from 'winston'
|
||||
import TYPES from '../Bootstrap/Types'
|
||||
import { TYPES } from '../Bootstrap/Types'
|
||||
import { TokenAuthenticationMethod } from './TokenAuthenticationMethod'
|
||||
|
||||
@injectable()
|
||||
|
||||
@@ -7,7 +7,7 @@ import { verify } from 'jsonwebtoken'
|
||||
import { AxiosError, AxiosInstance } from 'axios'
|
||||
import { Logger } from 'winston'
|
||||
|
||||
import TYPES from '../Bootstrap/Types'
|
||||
import { TYPES } from '../Bootstrap/Types'
|
||||
|
||||
@injectable()
|
||||
export class WebSocketAuthMiddleware extends BaseMiddleware {
|
||||
|
||||
22
packages/api-gateway/src/Controller/index.ts
Normal file
22
packages/api-gateway/src/Controller/index.ts
Normal file
@@ -0,0 +1,22 @@
|
||||
export * from './AuthMiddleware'
|
||||
export * from './HealthCheckController'
|
||||
export * from './LegacyController'
|
||||
export * from './SubscriptionTokenAuthMiddleware'
|
||||
export * from './TokenAuthenticationMethod'
|
||||
export * from './WebSocketAuthMiddleware'
|
||||
export * from './v1/ActionsController'
|
||||
export * from './v1/AuthenticatorsController'
|
||||
export * from './v1/FilesController'
|
||||
export * from './v1/InvoicesController'
|
||||
export * from './v1/ItemsController'
|
||||
export * from './v1/OfflineController'
|
||||
export * from './v1/PaymentsController'
|
||||
export * from './v1/RevisionsController'
|
||||
export * from './v1/SessionsController'
|
||||
export * from './v1/SubscriptionInvitesController'
|
||||
export * from './v1/TokensController'
|
||||
export * from './v1/UsersController'
|
||||
export * from './v1/WebSocketsController'
|
||||
export * from './v2/ActionsControllerV2'
|
||||
export * from './v2/PaymentsControllerV2'
|
||||
export * from './v2/RevisionsControllerV2'
|
||||
@@ -1,7 +1,7 @@
|
||||
import { Request, Response } from 'express'
|
||||
import { inject } from 'inversify'
|
||||
import { BaseHttpController, controller, httpGet, httpPost } from 'inversify-express-utils'
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v1')
|
||||
|
||||
@@ -2,7 +2,7 @@ import { inject } from 'inversify'
|
||||
import { Request, Response } from 'express'
|
||||
import { controller, BaseHttpController, httpPost, httpGet, httpDelete } from 'inversify-express-utils'
|
||||
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v1/authenticators')
|
||||
|
||||
@@ -2,7 +2,7 @@ import { Request, Response } from 'express'
|
||||
import { inject } from 'inversify'
|
||||
import { BaseHttpController, controller, httpPost } from 'inversify-express-utils'
|
||||
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v1/files')
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { Request, Response } from 'express'
|
||||
import { BaseHttpController, controller, httpPost } from 'inversify-express-utils'
|
||||
import { inject } from 'inversify'
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v1')
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { Request, Response } from 'express'
|
||||
import { inject } from 'inversify'
|
||||
import { BaseHttpController, controller, httpGet, httpPost } from 'inversify-express-utils'
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v1/items', TYPES.AuthMiddleware)
|
||||
|
||||
@@ -2,7 +2,7 @@ import { Request, Response } from 'express'
|
||||
import { inject } from 'inversify'
|
||||
import { BaseHttpController, controller, httpGet, httpPost } from 'inversify-express-utils'
|
||||
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v1/offline')
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { Request, Response } from 'express'
|
||||
import { inject } from 'inversify'
|
||||
import { all, BaseHttpController, controller, httpDelete, httpGet, httpPost } from 'inversify-express-utils'
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v1')
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { BaseHttpController, controller, httpDelete, httpGet, results } from 'inversify-express-utils'
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
|
||||
@controller('/v1/items/:item_id/revisions', TYPES.AuthMiddleware)
|
||||
export class RevisionsController extends BaseHttpController {
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { Request, Response } from 'express'
|
||||
import { inject } from 'inversify'
|
||||
import { BaseHttpController, controller, httpDelete, httpGet, httpPost } from 'inversify-express-utils'
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v1/sessions')
|
||||
|
||||
@@ -2,7 +2,7 @@ import { Request, Response } from 'express'
|
||||
import { inject } from 'inversify'
|
||||
import { BaseHttpController, controller, httpDelete, httpGet, httpPost } from 'inversify-express-utils'
|
||||
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v1/subscription-invites')
|
||||
|
||||
@@ -2,7 +2,7 @@ import { Request, Response } from 'express'
|
||||
import { inject } from 'inversify'
|
||||
import { BaseHttpController, controller, httpPost } from 'inversify-express-utils'
|
||||
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v1/subscription-tokens')
|
||||
|
||||
@@ -12,7 +12,7 @@ import {
|
||||
results,
|
||||
} from 'inversify-express-utils'
|
||||
import { Logger } from 'winston'
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
import { TokenAuthenticationMethod } from '../TokenAuthenticationMethod'
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@ import { inject } from 'inversify'
|
||||
import { BaseHttpController, controller, httpDelete, httpPost } from 'inversify-express-utils'
|
||||
import { Logger } from 'winston'
|
||||
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v1/sockets')
|
||||
|
||||
@@ -2,7 +2,7 @@ import { Request, Response } from 'express'
|
||||
import { inject } from 'inversify'
|
||||
import { BaseHttpController, controller, httpPost } from 'inversify-express-utils'
|
||||
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v2')
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { Request, Response } from 'express'
|
||||
import { BaseHttpController, controller, httpDelete, httpGet, httpPatch, httpPost } from 'inversify-express-utils'
|
||||
import { inject } from 'inversify'
|
||||
import TYPES from '../../Bootstrap/Types'
|
||||
import { TYPES } from '../../Bootstrap/Types'
|
||||
import { HttpServiceInterface } from '../../Service/Http/HttpServiceInterface'
|
||||
|
||||
@controller('/v2')
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user