mirror of
https://github.com/hcengineering/platform.git
synced 2025-04-13 19:58:09 +00:00
fix: remove unused elastic url (#7436)
This commit is contained in:
parent
a62625f29f
commit
9dc36f91c2
7
.vscode/launch.json
vendored
7
.vscode/launch.json
vendored
@ -181,7 +181,6 @@
|
||||
"request": "launch",
|
||||
"args": ["src/__start.ts"],
|
||||
"env": {
|
||||
"ELASTIC_URL": "http://localhost:9200",
|
||||
"MONGO_URL": "mongodb://localhost:27017",
|
||||
"METRICS_CONSOLE": "false",
|
||||
"STORAGE_CONFIG": "minio|localhost?accessKey=minioadmin&secretKey=minioadmin",
|
||||
@ -264,8 +263,7 @@
|
||||
"SERVER_SECRET": "secret",
|
||||
"MONGO_URL": "mongodb://localhost:27017",
|
||||
"ACCOUNTS_URL": "http://localhost:3000",
|
||||
"TELEGRAM_DATABASE": "telegram-service",
|
||||
"ELASTIC_URL": "http://localhost:9200"
|
||||
"TELEGRAM_DATABASE": "telegram-service"
|
||||
},
|
||||
"runtimeArgs": ["--nolazy", "-r", "ts-node/register"],
|
||||
"sourceMaps": true,
|
||||
@ -290,7 +288,6 @@
|
||||
"DB_URL": "mongodb://localhost:27017",
|
||||
"ACCOUNTS_URL": "http://localhost:3000",
|
||||
"TELEGRAM_DATABASE": "telegram-service",
|
||||
"ELASTIC_URL": "http://localhost:9200",
|
||||
"REKONI_URL": "http://localhost:4004",
|
||||
"MODEL_VERSION": "0.6.287"
|
||||
},
|
||||
@ -318,7 +315,6 @@
|
||||
"DB_URL": "postgresql://root@host.docker.internal:26257/defaultdb?sslmode=disable",
|
||||
"MONGO_URL": "mongodb://localhost:27017",
|
||||
"TELEGRAM_DATABASE": "telegram-service",
|
||||
"ELASTIC_URL": "http://localhost:9200",
|
||||
"REKONI_URL": "http://localhost:4004",
|
||||
"MODEL_VERSION": "0.6.287"
|
||||
},
|
||||
@ -342,7 +338,6 @@
|
||||
"DB_URL": "postgresql://postgres:example@localhost:5432",
|
||||
"ACCOUNTS_URL": "http://localhost:3000",
|
||||
"TELEGRAM_DATABASE": "telegram-service",
|
||||
"ELASTIC_URL": "http://localhost:9200",
|
||||
"REKONI_URL": "http://localhost:4004"
|
||||
},
|
||||
"runtimeVersion": "20",
|
||||
|
@ -232,7 +232,6 @@ services:
|
||||
- ACCOUNTS_URL=http://host.docker.internal:3000
|
||||
- STATS_URL=http://host.docker.internal:4900
|
||||
- UPLOAD_URL=/files
|
||||
- ELASTIC_URL=http://host.docker.internal:9200
|
||||
- GMAIL_URL=http://host.docker.internal:8088
|
||||
- CALENDAR_URL=http://host.docker.internal:8095
|
||||
- TELEGRAM_URL=http://host.docker.internal:8086
|
||||
|
@ -19,8 +19,8 @@
|
||||
"docker:tbuild": "docker build -t hardcoreeng/import-tool . --platform=linux/amd64 && ../../common/scripts/docker_tag_push.sh hardcoreeng/import-tool",
|
||||
"docker:staging": "../../common/scripts/docker_tag.sh hardcoreeng/import-tool staging",
|
||||
"docker:push": "../../common/scripts/docker_tag.sh hardcoreeng/import-tool",
|
||||
"run-local": "rush bundle --to @hcengineering/import-tool >/dev/null && cross-env SERVER_SECRET=secret ACCOUNTS_URL=http://localhost:3000 TRANSACTOR_URL=ws://localhost:3333 MINIO_ACCESS_KEY=minioadmin MINIO_SECRET_KEY=minioadmin MINIO_ENDPOINT=localhost MONGO_URL=mongodb://localhost:27017 TELEGRAM_DATABASE=telegram-service ELASTIC_URL=http://localhost:9200 REKONI_URL=http://localhost:4004 MODEL_VERSION=$(node ../../common/scripts/show_version.js) GIT_REVISION=$(git describe --all --long) node --max-old-space-size=18000 ./bundle/bundle.js",
|
||||
"run-local-brk": "rush bundle --to @hcengineering/import-tool >/dev/null && cross-env SERVER_SECRET=secret ACCOUNTS_URL=http://localhost:3000 TRANSACTOR_URL=ws://localhost:3333 MINIO_ACCESS_KEY=minioadmin MINIO_SECRET_KEY=minioadmin MINIO_ENDPOINT=localhost MONGO_URL=mongodb://localhost:27017 TELEGRAM_DATABASE=telegram-service ELASTIC_URL=http://localhost:9200 REKONI_URL=http://localhost:4004 MODEL_VERSION=$(node ../../common/scripts/show_version.js) GIT_REVISION=$(git describe --all --long) node --inspect-brk --enable-source-maps --max-old-space-size=18000 ./bundle/bundle.js",
|
||||
"run-local": "rush bundle --to @hcengineering/import-tool >/dev/null && cross-env SERVER_SECRET=secret ACCOUNTS_URL=http://localhost:3000 TRANSACTOR_URL=ws://localhost:3333 MINIO_ACCESS_KEY=minioadmin MINIO_SECRET_KEY=minioadmin MINIO_ENDPOINT=localhost MONGO_URL=mongodb://localhost:27017 TELEGRAM_DATABASE=telegram-service REKONI_URL=http://localhost:4004 MODEL_VERSION=$(node ../../common/scripts/show_version.js) GIT_REVISION=$(git describe --all --long) node --max-old-space-size=18000 ./bundle/bundle.js",
|
||||
"run-local-brk": "rush bundle --to @hcengineering/import-tool >/dev/null && cross-env SERVER_SECRET=secret ACCOUNTS_URL=http://localhost:3000 TRANSACTOR_URL=ws://localhost:3333 MINIO_ACCESS_KEY=minioadmin MINIO_SECRET_KEY=minioadmin MINIO_ENDPOINT=localhost MONGO_URL=mongodb://localhost:27017 TELEGRAM_DATABASE=telegram-service REKONI_URL=http://localhost:4004 MODEL_VERSION=$(node ../../common/scripts/show_version.js) GIT_REVISION=$(git describe --all --long) node --inspect-brk --enable-source-maps --max-old-space-size=18000 ./bundle/bundle.js",
|
||||
"run": "rush bundle --to @hcengineering/import-tool >/dev/null && cross-env node --max-old-space-size=8000 ./bundle/bundle.js",
|
||||
"upgrade": "rushx run-local upgrade",
|
||||
"format": "format src",
|
||||
|
@ -87,7 +87,6 @@ services:
|
||||
- 'MONGO_OPTIONS={"appName":"front","maxPoolSize":1}'
|
||||
- ACCOUNTS_URL=http://localhost:3000
|
||||
- UPLOAD_URL=/files
|
||||
- ELASTIC_URL=http://elastic:9200
|
||||
- GMAIL_URL=http://localhost:8088
|
||||
- CALENDAR_URL=http://localhost:8095
|
||||
- TELEGRAM_URL=http://localhost:8086
|
||||
@ -121,7 +120,6 @@ services:
|
||||
- SERVER_PORT=3333
|
||||
- SERVER_SECRET=secret
|
||||
- ENABLE_COMPRESSION=true
|
||||
- ELASTIC_URL=http://elastic:9200
|
||||
- MONGO_URL=mongodb://host.docker.internal:27017?compressors=snappy
|
||||
- 'MONGO_OPTIONS={"appName": "transactor", "maxPoolSize": 10}'
|
||||
- METRICS_CONSOLE=false
|
||||
|
@ -19,10 +19,10 @@
|
||||
"docker:tbuild": "docker build -t hardcoreeng/tool . --platform=linux/amd64 && ../../common/scripts/docker_tag_push.sh hardcoreeng/tool",
|
||||
"docker:staging": "../../common/scripts/docker_tag.sh hardcoreeng/tool staging",
|
||||
"docker:push": "../../common/scripts/docker_tag.sh hardcoreeng/tool",
|
||||
"run-local": "rush bundle --to @hcengineering/tool >/dev/null && cross-env SERVER_SECRET=secret ACCOUNTS_URL=http://localhost:3000 TRANSACTOR_URL=ws://localhost:3333 MINIO_ACCESS_KEY=minioadmin MINIO_SECRET_KEY=minioadmin MINIO_ENDPOINT=localhost ACCOUNT_DB_URL=mongodb://localhost:27017 DB_URL=mongodb://localhost:27017 TELEGRAM_DATABASE=telegram-service ELASTIC_URL=http://localhost:9200 REKONI_URL=http://localhost:4004 MODEL_VERSION=$(node ../../common/scripts/show_version.js) GIT_REVISION=$(git describe --all --long) node --expose-gc --max-old-space-size=18000 ./bundle/bundle.js",
|
||||
"run-local-pg": "rush bundle --to @hcengineering/tool >/dev/null && cross-env SERVER_SECRET=secret ACCOUNTS_URL=http://localhost:3000 TRANSACTOR_URL=ws://localhost:3333 MINIO_ACCESS_KEY=minioadmin MINIO_SECRET_KEY=minioadmin MINIO_ENDPOINT=localhost ACCOUNT_DB_URL=mongodb://localhost:27017 DB_URL=postgresql://postgres:example@localhost:5432 TELEGRAM_DATABASE=telegram-service ELASTIC_URL=http://localhost:9200 REKONI_URL=http://localhost:4004 MODEL_VERSION=$(node ../../common/scripts/show_version.js) GIT_REVISION=$(git describe --all --long) node --expose-gc --max-old-space-size=18000 ./bundle/bundle.js",
|
||||
"run-local-cr": "rush bundle --to @hcengineering/tool >/dev/null && cross-env SERVER_SECRET=secret ACCOUNTS_URL=http://localhost:3000 TRANSACTOR_URL=ws://localhost:3332 MINIO_ACCESS_KEY=minioadmin MINIO_SECRET_KEY=minioadmin MINIO_ENDPOINT=localhost ACCOUNT_DB_URL=mongodb://localhost:27017 DB_URL=postgresql://root@host.docker.internal:26257/defaultdb?sslmode=disable TELEGRAM_DATABASE=telegram-service ELASTIC_URL=http://localhost:9200 REKONI_URL=http://localhost:4004 MODEL_VERSION=$(node ../../common/scripts/show_version.js) GIT_REVISION=$(git describe --all --long) node --expose-gc --max-old-space-size=18000 ./bundle/bundle.js",
|
||||
"run-local-brk": "rush bundle --to @hcengineering/tool >/dev/null && cross-env SERVER_SECRET=secret ACCOUNTS_URL=http://localhost:3000 TRANSACTOR_URL=ws://localhost:3333 MINIO_ACCESS_KEY=minioadmin MINIO_SECRET_KEY=minioadmin MINIO_ENDPOINT=localhost ACCOUNT_DB_URL=mongodb://localhost:27017 DB_URL=mongodb://localhost:27017 TELEGRAM_DATABASE=telegram-service ELASTIC_URL=http://localhost:9200 REKONI_URL=http://localhost:4004 MODEL_VERSION=$(node ../../common/scripts/show_version.js) GIT_REVISION=$(git describe --all --long) node --inspect-brk --enable-source-maps --max-old-space-size=18000 ./bundle/bundle.js",
|
||||
"run-local": "rush bundle --to @hcengineering/tool >/dev/null && cross-env SERVER_SECRET=secret ACCOUNTS_URL=http://localhost:3000 TRANSACTOR_URL=ws://localhost:3333 MINIO_ACCESS_KEY=minioadmin MINIO_SECRET_KEY=minioadmin MINIO_ENDPOINT=localhost ACCOUNT_DB_URL=mongodb://localhost:27017 DB_URL=mongodb://localhost:27017 TELEGRAM_DATABASE=telegram-service REKONI_URL=http://localhost:4004 MODEL_VERSION=$(node ../../common/scripts/show_version.js) GIT_REVISION=$(git describe --all --long) node --expose-gc --max-old-space-size=18000 ./bundle/bundle.js",
|
||||
"run-local-pg": "rush bundle --to @hcengineering/tool >/dev/null && cross-env SERVER_SECRET=secret ACCOUNTS_URL=http://localhost:3000 TRANSACTOR_URL=ws://localhost:3333 MINIO_ACCESS_KEY=minioadmin MINIO_SECRET_KEY=minioadmin MINIO_ENDPOINT=localhost ACCOUNT_DB_URL=mongodb://localhost:27017 DB_URL=postgresql://postgres:example@localhost:5432 TELEGRAM_DATABASE=telegram-service REKONI_URL=http://localhost:4004 MODEL_VERSION=$(node ../../common/scripts/show_version.js) GIT_REVISION=$(git describe --all --long) node --expose-gc --max-old-space-size=18000 ./bundle/bundle.js",
|
||||
"run-local-cr": "rush bundle --to @hcengineering/tool >/dev/null && cross-env SERVER_SECRET=secret ACCOUNTS_URL=http://localhost:3000 TRANSACTOR_URL=ws://localhost:3332 MINIO_ACCESS_KEY=minioadmin MINIO_SECRET_KEY=minioadmin MINIO_ENDPOINT=localhost ACCOUNT_DB_URL=mongodb://localhost:27017 DB_URL=postgresql://root@host.docker.internal:26257/defaultdb?sslmode=disable TELEGRAM_DATABASE=telegram-service REKONI_URL=http://localhost:4004 MODEL_VERSION=$(node ../../common/scripts/show_version.js) GIT_REVISION=$(git describe --all --long) node --expose-gc --max-old-space-size=18000 ./bundle/bundle.js",
|
||||
"run-local-brk": "rush bundle --to @hcengineering/tool >/dev/null && cross-env SERVER_SECRET=secret ACCOUNTS_URL=http://localhost:3000 TRANSACTOR_URL=ws://localhost:3333 MINIO_ACCESS_KEY=minioadmin MINIO_SECRET_KEY=minioadmin MINIO_ENDPOINT=localhost ACCOUNT_DB_URL=mongodb://localhost:27017 DB_URL=mongodb://localhost:27017 TELEGRAM_DATABASE=telegram-service REKONI_URL=http://localhost:4004 MODEL_VERSION=$(node ../../common/scripts/show_version.js) GIT_REVISION=$(git describe --all --long) node --inspect-brk --enable-source-maps --max-old-space-size=18000 ./bundle/bundle.js",
|
||||
"run": "rush bundle --to @hcengineering/tool >/dev/null && cross-env node --max-old-space-size=8000 ./bundle/bundle.js",
|
||||
"upgrade": "rushx run-local upgrade",
|
||||
"format": "format src",
|
||||
|
@ -82,7 +82,6 @@ export async function cleanWorkspace (
|
||||
mongoUrl: string,
|
||||
workspaceId: WorkspaceId,
|
||||
storageAdapter: StorageAdapter,
|
||||
elasticUrl: string,
|
||||
transactorUrl: string,
|
||||
opt: { recruit: boolean, tracker: boolean, removedTx: boolean }
|
||||
): Promise<void> {
|
||||
|
@ -167,15 +167,6 @@ export function devTool (
|
||||
console.error('please provide transactor url.')
|
||||
}
|
||||
|
||||
function getElasticUrl (): string {
|
||||
const elasticUrl = process.env.ELASTIC_URL
|
||||
if (elasticUrl === undefined) {
|
||||
console.error('please provide elastic url')
|
||||
process.exit(1)
|
||||
}
|
||||
return elasticUrl
|
||||
}
|
||||
|
||||
const initScriptUrl = process.env.INIT_SCRIPT_URL
|
||||
if (initScriptUrl !== undefined) {
|
||||
setMetadata(toolPlugin.metadata.InitScriptURL, initScriptUrl)
|
||||
@ -1443,7 +1434,7 @@ export function devTool (
|
||||
await withDatabase(dbUrl, async (db) => {
|
||||
const wsid = getWorkspaceId(workspace)
|
||||
const endpoint = await getTransactorEndpoint(generateToken(systemAccountEmail, wsid), 'external')
|
||||
await cleanWorkspace(toolCtx, dbUrl, wsid, adapter, getElasticUrl(), endpoint, cmd)
|
||||
await cleanWorkspace(toolCtx, dbUrl, wsid, adapter, endpoint, cmd)
|
||||
})
|
||||
})
|
||||
})
|
||||
|
@ -2,7 +2,6 @@
|
||||
|
||||
export ACCOUNTS_URL=http://localhost:3333
|
||||
export UPLOAD_URL=http://localhost:3333/files
|
||||
export ELASTIC_URL=http://elastic:9200
|
||||
export COLLABORATOR_URL=ws://localhost:3078
|
||||
export MINIO_ENDPOINT=minio
|
||||
export MINIO_ACCESS_KEY=minioadmin
|
||||
|
@ -99,7 +99,6 @@ services:
|
||||
- ACCOUNTS_URL=http://host.docker.internal:3003
|
||||
- MONGO_URL=mongodb://mongodb:27018
|
||||
- UPLOAD_URL=/files
|
||||
- ELASTIC_URL=http://elastic:9200
|
||||
- GMAIL_URL=http://host.docker.internal:8088
|
||||
- CALENDAR_URL=http://host.docker.internal:8095
|
||||
- REKONI_URL=http://rekoni:4007
|
||||
|
@ -3,7 +3,6 @@ export MINIO_ACCESS_KEY=minioadmin
|
||||
export MINIO_SECRET_KEY=minioadmin
|
||||
export MINIO_ENDPOINT=localhost:9000
|
||||
export MONGO_URL=mongodb://localhost:27017
|
||||
export ELASTIC_URL=http://localhost:9200
|
||||
export SERVER_SECRET=secret
|
||||
|
||||
# Restore workspace contents in mongo/elastic
|
||||
|
@ -7,7 +7,6 @@ export DB_URL=mongodb://localhost:27017
|
||||
export ACCOUNT_DB_URL=mongodb://localhost:27017
|
||||
export ACCOUNTS_URL=http://localhost:3000
|
||||
export TRANSACTOR_URL=ws://localhost:3333
|
||||
export ELASTIC_URL=http://localhost:9200
|
||||
export SERVER_SECRET=secret
|
||||
|
||||
# Restore workspace contents in mongo/elastic
|
||||
|
@ -8,7 +8,6 @@ export TRANSACTOR_URL=ws://localhost:3334
|
||||
export MONGO_URL=mongodb://localhost:27018
|
||||
export ACCOUNT_DB_URL=mongodb://localhost:27018
|
||||
export DB_URL=mongodb://localhost:27018
|
||||
export ELASTIC_URL=http://localhost:9201
|
||||
export SERVER_SECRET=secret
|
||||
export STORAGE_CONFIG="minio|localhost:9002?accessKey=minioadmin&secretKey=minioadmin"
|
||||
|
||||
|
@ -6,7 +6,6 @@ Front service is suited to deliver application bundles and resource assets, it a
|
||||
|
||||
* SERVER_PORT: Specifies the port number on which the server will listen.
|
||||
* MONGO_URL: Specifies the URL of the MongoDB database.
|
||||
* ELASTIC_URL: Specifies the URL of the Elasticsearch service.
|
||||
* ACCOUNTS_URL: Specifies the URL of the accounts service.
|
||||
* UPLOAD_URL: Specifies the URL for uploading files.
|
||||
* GMAIL_URL: Specifies the URL of the Gmail service.
|
||||
|
@ -2,7 +2,6 @@
|
||||
|
||||
export ACCOUNTS_URL=http://localhost:3333
|
||||
export UPLOAD_URL=http://localhost:3333/files
|
||||
export ELASTIC_URL=http://elastic:9200
|
||||
export MINIO_ENDPOINT=minio
|
||||
export MINIO_ACCESS_KEY=minioadmin
|
||||
export MINIO_SECRET_KEY=minioadmin
|
||||
|
@ -243,7 +243,6 @@ async function getFile (
|
||||
export function start (
|
||||
ctx: MeasureContext,
|
||||
config: {
|
||||
elasticUrl: string
|
||||
storageAdapter: StorageAdapter
|
||||
accountsUrl: string
|
||||
uploadUrl: string
|
||||
|
@ -24,12 +24,6 @@ import { start } from '.'
|
||||
export function startFront (ctx: MeasureContext, extraConfig?: Record<string, string | undefined>): void {
|
||||
const SERVER_PORT = parseInt(process.env.SERVER_PORT ?? '8080')
|
||||
|
||||
const elasticUrl = process.env.ELASTIC_URL
|
||||
if (elasticUrl === undefined) {
|
||||
console.error('please provide elastic url')
|
||||
process.exit(1)
|
||||
}
|
||||
|
||||
const storageConfig: StorageConfiguration = storageConfigFromEnv()
|
||||
const storageAdapter = buildStorageFromConfig(storageConfig)
|
||||
|
||||
@ -120,7 +114,6 @@ export function startFront (ctx: MeasureContext, extraConfig?: Record<string, st
|
||||
const disableSignUp = process.env.DISABLE_SIGNUP
|
||||
|
||||
const config = {
|
||||
elasticUrl,
|
||||
storageAdapter,
|
||||
accountsUrl,
|
||||
uploadUrl,
|
||||
|
Loading…
Reference in New Issue
Block a user