From 9d140ee450cb3d8e974dc781dd72f5b73e67a778 Mon Sep 17 00:00:00 2001 From: Daniel Brooks Date: Tue, 8 Oct 2024 12:34:03 -0700 Subject: [PATCH] feat(otel): creating the otel collector service (#801) * feat(otel): creating the otel collector service * fix(otel): ensuring service will start * fix(otel): update image name --- .github/workflows/otel-collector.yml | 41 +++ infrastructure/otel-collector/.gitignore | 4 + .../otel-collector/.terraform-version | 1 + infrastructure/otel-collector/cdktf.json | 5 + .../otel-collector/eslint.config.mjs | 3 + infrastructure/otel-collector/package.json | 32 ++ .../otel-collector/src/config/index.ts | 36 +++ infrastructure/otel-collector/src/main.ts | 183 +++++++++++ infrastructure/otel-collector/tsconfig.json | 14 + pnpm-lock.yaml | 287 +++++++++++++----- servers/otel-collector/Dockerfile | 21 ++ servers/otel-collector/entrypoint.sh | 5 + servers/otel-collector/httpd.conf | 15 + .../otel-collector/otel-collector-config.yaml | 85 ++++++ 14 files changed, 648 insertions(+), 84 deletions(-) create mode 100644 .github/workflows/otel-collector.yml create mode 100644 infrastructure/otel-collector/.gitignore create mode 100644 infrastructure/otel-collector/.terraform-version create mode 100644 infrastructure/otel-collector/cdktf.json create mode 100644 infrastructure/otel-collector/eslint.config.mjs create mode 100644 infrastructure/otel-collector/package.json create mode 100644 infrastructure/otel-collector/src/config/index.ts create mode 100644 infrastructure/otel-collector/src/main.ts create mode 100644 infrastructure/otel-collector/tsconfig.json create mode 100644 servers/otel-collector/Dockerfile create mode 100644 servers/otel-collector/entrypoint.sh create mode 100644 servers/otel-collector/httpd.conf create mode 100644 servers/otel-collector/otel-collector-config.yaml diff --git a/.github/workflows/otel-collector.yml b/.github/workflows/otel-collector.yml new file mode 100644 index 000000000..f2386de88 --- /dev/null +++ b/.github/workflows/otel-collector.yml @@ -0,0 +1,41 @@ +name: OTEL Collector +on: + pull_request: + paths: + - 'infrastructure/otel-collector/**' + - 'packages/**' + - 'docker-compose.yml' + - 'servers/otel-collector/**' + - '.github/actions/**' + - '.github/workflows/otel-collector.yml' + - '.github/workflows/reuse-*.yml' + push: + branches: + - main + - dev + paths: + - 'infrastructure/otel-collector/**' + - 'packages/**' + - 'servers/otel-collector/**' + - '.github/actions/**' + - '.github/workflows/otel-collector.yml' + - '.github/workflows/reuse-*.yml' +jobs: + + infrastructure: + uses: ./.github/workflows/reuse-infrastructure.yml + with: + scope: otel-collector-cdk + stack-output-path: infrastructure/otel-collector/cdktf.out/stacks/otel-collector + secrets: inherit + + api: + uses: ./.github/workflows/reuse-build-and-push-image.yml + needs: [infrastructure] + with: + scope: otel-collector + docker-repo-name-pattern: otelcollector-{0}-app + context: servers/otel-collector + app-path: servers/otel-collector + terraform-output: ${{needs.infrastructure.outputs.terraform-output}} + secrets: inherit \ No newline at end of file diff --git a/infrastructure/otel-collector/.gitignore b/infrastructure/otel-collector/.gitignore new file mode 100644 index 000000000..34031a4dd --- /dev/null +++ b/infrastructure/otel-collector/.gitignore @@ -0,0 +1,4 @@ +.terraform/ +node_modules/ +cdktf.out/ +.gen/ \ No newline at end of file diff --git a/infrastructure/otel-collector/.terraform-version b/infrastructure/otel-collector/.terraform-version new file mode 100644 index 000000000..fe4e75fb7 --- /dev/null +++ b/infrastructure/otel-collector/.terraform-version @@ -0,0 +1 @@ +1.8.3 \ No newline at end of file diff --git a/infrastructure/otel-collector/cdktf.json b/infrastructure/otel-collector/cdktf.json new file mode 100644 index 000000000..defc3ea13 --- /dev/null +++ b/infrastructure/otel-collector/cdktf.json @@ -0,0 +1,5 @@ +{ + "language": "typescript", + "app": "npm run --silent compile && node dist/main.js", + "projectId": "7e0b548c-601b-4fd5-9387-cd9ad7f5007c" +} diff --git a/infrastructure/otel-collector/eslint.config.mjs b/infrastructure/otel-collector/eslint.config.mjs new file mode 100644 index 000000000..1f5684f1b --- /dev/null +++ b/infrastructure/otel-collector/eslint.config.mjs @@ -0,0 +1,3 @@ +import cdktf from '@pocket-tools/eslint-config/cdktf'; +import tseslint from 'typescript-eslint'; +export default tseslint.config(...cdktf); diff --git a/infrastructure/otel-collector/package.json b/infrastructure/otel-collector/package.json new file mode 100644 index 000000000..3590c7c5c --- /dev/null +++ b/infrastructure/otel-collector/package.json @@ -0,0 +1,32 @@ +{ + "name": "otel-collector-cdk", + "version": "1.0.0", + "private": true, + "main": "dist/main.js", + "types": "src/main.ts", + "scripts": { + "build": "rm -rf dist && tsc", + "compile": "tsc --pretty", + "format": "eslint --fix", + "lint": "eslint --fix-dry-run", + "synth": "cdktf synth", + "watch": "tsc -w" + }, + "dependencies": { + "@cdktf/provider-aws": "19.33.0", + "@cdktf/provider-local": "10.1.0", + "@cdktf/provider-null": "10.0.0", + "@cdktf/provider-pagerduty": "13.11.6", + "@pocket-tools/terraform-modules": "workspace:*", + "cdktf": "0.20.8", + "cdktf-cli": "0.20.8", + "constructs": "10.3.0" + }, + "devDependencies": { + "@pocket-tools/eslint-config": "workspace:*", + "@types/node": "^22.5.2", + "ts-node": "10.9.2", + "tsconfig": "workspace:*", + "typescript": "5.5.4" + } +} diff --git a/infrastructure/otel-collector/src/config/index.ts b/infrastructure/otel-collector/src/config/index.ts new file mode 100644 index 000000000..942bacf54 --- /dev/null +++ b/infrastructure/otel-collector/src/config/index.ts @@ -0,0 +1,36 @@ +const name = 'OtelCollector'; +const domainPrefix = 'otel-collector'; +const isDev = process.env.NODE_ENV === 'development'; +const environment = isDev ? 'Dev' : 'Prod'; +const domain = isDev + ? `${domainPrefix}.getpocket.dev` + : `${domainPrefix}.readitlater.com`; +const isProd = process.env.NODE_ENV === 'production'; +const releaseSha = process.env.CIRCLE_SHA1; + +export const config = { + name, + isProd, + prefix: `${name}-${environment}`, + shortName: 'OTEL', + environment, + domain, + isDev, + releaseSha, + tags: { + service: name, + environment, + owner: 'Pocket', + costCenter: 'Shared', + app_code: 'pocket', + component_code: `pocket-${name.toLowerCase()}`, + env_code: isDev ? 'dev' : 'prod', + }, + healthCheck: { + command: ['CMD-SHELL', 'curl -f http://localhost:3000/status || exit 1'], + interval: 15, + retries: 3, + timeout: 5, + startPeriod: 0, + }, +}; diff --git a/infrastructure/otel-collector/src/main.ts b/infrastructure/otel-collector/src/main.ts new file mode 100644 index 000000000..056475a3b --- /dev/null +++ b/infrastructure/otel-collector/src/main.ts @@ -0,0 +1,183 @@ +import { config } from './config'; + +import { + provider as awsProvider, + cloudwatchLogGroup, + dataAwsCallerIdentity, + dataAwsRegion, + dataAwsKmsAlias, + dataAwsSnsTopic, +} from '@cdktf/provider-aws'; +import { provider as localProvider } from '@cdktf/provider-local'; +import { provider as nullProvider } from '@cdktf/provider-null'; +import { PocketALBApplication } from '@pocket-tools/terraform-modules'; + +import { App, S3Backend, TerraformStack } from 'cdktf'; +import { Construct } from 'constructs'; +import fs from 'fs'; + +class OTELCollector extends TerraformStack { + constructor(scope: Construct, name: string) { + super(scope, name); + + new awsProvider.AwsProvider(this, 'aws', { + region: 'us-east-1', + defaultTags: [{ tags: config.tags }], + }); + new localProvider.LocalProvider(this, 'local_provider'); + new nullProvider.NullProvider(this, 'null_provider'); + new S3Backend(this, { + bucket: `mozilla-pocket-team-${config.environment.toLowerCase()}-terraform-state`, + dynamodbTable: `mozilla-pocket-team-${config.environment.toLowerCase()}-terraform-state`, + key: config.name, + region: 'us-east-1', + }); + + const caller = new dataAwsCallerIdentity.DataAwsCallerIdentity( + this, + 'caller', + ); + const region = new dataAwsRegion.DataAwsRegion(this, 'region'); + + const alarmTopic = this.getCodeDeploySnsTopic(); + + this.createPocketAlbApplication({ + secretsManagerKmsAlias: this.getSecretsManagerKmsAlias(), + snsTopic: alarmTopic, + region, + caller, + }); + } + + /** + * Get the sns topic for code deploy + * @private + */ + private getCodeDeploySnsTopic() { + return new dataAwsSnsTopic.DataAwsSnsTopic(this, 'backend_notifications', { + name: `Backend-${config.environment}-ChatBot`, + }); + } + + /** + * Get secrets manager kms alias + * @private + */ + private getSecretsManagerKmsAlias() { + return new dataAwsKmsAlias.DataAwsKmsAlias(this, 'kms_alias', { + name: 'alias/aws/secretsmanager', + }); + } + + private createPocketAlbApplication(dependencies: { + region: dataAwsRegion.DataAwsRegion; + caller: dataAwsCallerIdentity.DataAwsCallerIdentity; + secretsManagerKmsAlias: dataAwsKmsAlias.DataAwsKmsAlias; + snsTopic: dataAwsSnsTopic.DataAwsSnsTopic; + }): PocketALBApplication { + const { region, caller, secretsManagerKmsAlias, snsTopic } = dependencies; + + return new PocketALBApplication(this, 'application', { + internal: true, + prefix: config.prefix, + alb6CharacterPrefix: config.shortName, + tags: config.tags, + cdn: false, + domain: config.domain, + taskSize: { + cpu: 2048, + memory: 4096, + }, + containerConfigs: [ + { + healthCheck: config.healthCheck, + name: 'app', + essential: true, + portMappings: [{ containerPort: 3000, hostPort: 3000 }], + logMultilinePattern: '^\\S.+', + logGroup: this.createCustomLogGroup('otel-collector'), + envVars: [ + { + name: 'DEPLOYMENT_ENVIRONMENT_NAME', + value: config.tags.env_code, + }, + ], + secretEnvVars: [ + { + name: 'GOOGLE_APPLICATION_CREDENTIALS_JSON', + valueFrom: `arn:aws:secretsmanager:${region.name}:${caller.accountId}:secret:Shared/GCP_SA_TRACES:::`, + }, + ], + }, + ], + codeDeploy: { + useCodeDeploy: true, + useCodePipeline: false, + useTerraformBasedCodeDeploy: false, + generateAppSpec: false, + snsNotificationTopicArn: snsTopic.arn, + successTerminationWaitTimeInMinutes: 5, + notifications: { + //only notify on failed deploys + notifyOnFailed: true, + notifyOnStarted: false, + notifyOnSucceeded: false, + }, + }, + exposedContainer: { + name: 'app', + port: 3000, + healthCheckPath: '/status', + }, + ecsIamConfig: { + prefix: config.prefix, + taskExecutionRolePolicyStatements: [ + //This policy could probably go in the shared module in the future. + { + actions: ['secretsmanager:GetSecretValue', 'kms:Decrypt'], + resources: [ + `arn:aws:secretsmanager:${region.name}:${caller.accountId}:secret:Shared`, + `arn:aws:secretsmanager:${region.name}:${caller.accountId}:secret:Shared/*`, + secretsManagerKmsAlias.targetKeyArn, + ], + effect: 'Allow', + }, + ], + taskRolePolicyStatements: [], + taskExecutionDefaultAttachmentArn: + 'arn:aws:iam::aws:policy/service-role/AmazonECSTaskExecutionRolePolicy', + }, + autoscalingConfig: { + targetMinCapacity: config.isProd ? 4 : 1, + targetMaxCapacity: config.isProd ? 20 : 10, + }, + alarms: {}, + }); + } + + /** + * Create Custom log group for ECS to share across task revisions + * @param containerName + * @private + */ + private createCustomLogGroup(containerName: string) { + const logGroup = new cloudwatchLogGroup.CloudwatchLogGroup( + this, + `${containerName}-log-group`, + { + name: `/Backend/${config.prefix}/ecs/${containerName}`, + retentionInDays: 90, + skipDestroy: true, + tags: config.tags, + }, + ); + + return logGroup.name; + } +} + +const app = new App(); +const stack = new OTELCollector(app, 'otel-collector'); +const tfEnvVersion = fs.readFileSync('.terraform-version', 'utf8'); +stack.addOverride('terraform.required_version', tfEnvVersion); +app.synth(); diff --git a/infrastructure/otel-collector/tsconfig.json b/infrastructure/otel-collector/tsconfig.json new file mode 100644 index 000000000..10c750597 --- /dev/null +++ b/infrastructure/otel-collector/tsconfig.json @@ -0,0 +1,14 @@ +{ + "extends": "tsconfig/cdktf.json", + "compilerOptions": { + "outDir": "dist", + "rootDir": "src" + }, + "exclude": [ + "node_modules/", + "dist/" + ], + "include": [ + "src/**/*.ts", + ] +} diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index bed1b4702..c1fd4b5ac 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -17,7 +17,7 @@ importers: devDependencies: '@commitlint/cli': specifier: 19.4.1 - version: 19.4.1(@types/node@22.5.5)(typescript@5.7.0-dev.20241008) + version: 19.4.1(@types/node@22.7.4)(typescript@5.7.0-dev.20241008) '@commitlint/config-conventional': specifier: ^19.4.1 version: 19.4.1 @@ -56,7 +56,7 @@ importers: version: 0.20.8(constructs@10.3.0) cdktf-cli: specifier: 0.20.8 - version: 0.20.8(encoding@0.1.13)(ink@5.0.1(react-devtools-core@4.28.5)(react@18.3.1))(react@18.3.1) + version: 0.20.8(encoding@0.1.13)(ink@3.2.0(react@18.3.1))(react@18.3.1) constructs: specifier: 10.3.0 version: 10.3.0 @@ -495,6 +495,49 @@ importers: specifier: 5.5.4 version: 5.5.4 + infrastructure/otel-collector: + dependencies: + '@cdktf/provider-aws': + specifier: 19.33.0 + version: 19.33.0(cdktf@0.20.8(constructs@10.3.0))(constructs@10.3.0) + '@cdktf/provider-local': + specifier: 10.1.0 + version: 10.1.0(cdktf@0.20.8(constructs@10.3.0))(constructs@10.3.0) + '@cdktf/provider-null': + specifier: 10.0.0 + version: 10.0.0(cdktf@0.20.8(constructs@10.3.0))(constructs@10.3.0) + '@cdktf/provider-pagerduty': + specifier: 13.11.6 + version: 13.11.6(cdktf@0.20.8(constructs@10.3.0))(constructs@10.3.0) + '@pocket-tools/terraform-modules': + specifier: workspace:* + version: link:../../packages/terraform-modules + cdktf: + specifier: 0.20.8 + version: 0.20.8(constructs@10.3.0) + cdktf-cli: + specifier: 0.20.8 + version: 0.20.8(encoding@0.1.13)(ink@5.0.1(react-devtools-core@4.28.5)(react@18.3.1))(react@18.3.1) + constructs: + specifier: 10.3.0 + version: 10.3.0 + devDependencies: + '@pocket-tools/eslint-config': + specifier: workspace:* + version: link:../../packages/eslint-config + '@types/node': + specifier: ^22.5.2 + version: 22.7.4 + ts-node: + specifier: 10.9.2 + version: 10.9.2(@types/node@22.7.4)(typescript@5.5.4) + tsconfig: + specifier: workspace:* + version: link:../../packages/tsconfig + typescript: + specifier: 5.5.4 + version: 5.5.4 + infrastructure/parser-graphql-wrapper: dependencies: '@cdktf/provider-archive': @@ -969,7 +1012,7 @@ importers: version: 14.0.0-beta.11 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.24.5)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.24.5))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1018,7 +1061,7 @@ importers: version: 14.0.0-beta.11 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1067,7 +1110,7 @@ importers: version: 14.0.0-beta.11 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1107,7 +1150,7 @@ importers: version: 14.0.0-beta.11 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1168,7 +1211,7 @@ importers: version: 3.1.4 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1220,7 +1263,7 @@ importers: version: 3.1.4 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1272,7 +1315,7 @@ importers: version: 29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1318,7 +1361,7 @@ importers: version: 29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1364,7 +1407,7 @@ importers: version: 14.0.0-beta.11 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1416,7 +1459,7 @@ importers: version: 3.1.4 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1471,7 +1514,7 @@ importers: version: 14.0.0-beta.11 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1532,7 +1575,7 @@ importers: version: 14.0.0-beta.11 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1572,7 +1615,7 @@ importers: version: 14.0.0-beta.11 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1618,7 +1661,7 @@ importers: version: 14.0.0-beta.11 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1673,7 +1716,7 @@ importers: version: 14.0.0-beta.11 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1761,7 +1804,7 @@ importers: version: 8.0.2(semantic-release@24.1.0(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1798,7 +1841,7 @@ importers: version: 29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1868,7 +1911,7 @@ importers: version: 29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1914,7 +1957,7 @@ importers: version: 8.0.2(semantic-release@24.1.0(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -1957,7 +2000,7 @@ importers: version: 29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -2012,7 +2055,7 @@ importers: version: 8.0.2(semantic-release@24.1.0(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -2058,7 +2101,7 @@ importers: version: 8.0.2(semantic-release@24.1.0(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -2104,7 +2147,7 @@ importers: version: 29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -2149,7 +2192,7 @@ importers: version: 0.20.8(constructs@10.3.0) cdktf-cli: specifier: 0.20.8 - version: 0.20.8(encoding@0.1.13)(ink@3.2.0(react@18.3.1))(react@18.3.1) + version: 0.20.8(encoding@0.1.13)(ink@5.0.1(react-devtools-core@4.28.5)(react@18.3.1))(react@18.3.1) constructs: specifier: 10.3.0 version: 10.3.0 @@ -2183,7 +2226,7 @@ importers: version: 8.0.2(semantic-release@24.1.0(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -2301,7 +2344,7 @@ importers: version: 8.0.2(semantic-release@24.1.0(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -2350,7 +2393,7 @@ importers: version: 8.0.2(semantic-release@24.1.0(typescript@5.5.4)) ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -2453,7 +2496,7 @@ importers: version: 7.0.0 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -2598,7 +2641,7 @@ importers: version: 7.0.0 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.24.8)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.24.8))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -2698,7 +2741,7 @@ importers: version: 7.0.0 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -2807,7 +2850,7 @@ importers: version: 3.1.4 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -2901,7 +2944,7 @@ importers: version: 7.0.0 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -3052,7 +3095,7 @@ importers: version: 7.0.0 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -3233,7 +3276,7 @@ importers: version: 7.0.0 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -3291,7 +3334,7 @@ importers: version: 3.1.4 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -3415,7 +3458,7 @@ importers: version: 7.0.0 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -3485,7 +3528,7 @@ importers: version: 3.1.4 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -3594,7 +3637,7 @@ importers: version: 7.0.0 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -3691,7 +3734,7 @@ importers: version: 7.0.0 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -3854,7 +3897,7 @@ importers: version: 7.0.0 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -3951,7 +3994,7 @@ importers: version: 7.0.0 ts-jest: specifier: 29.2.5 - version: 29.2.5(@babel/core@7.24.5)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.24.5))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) + version: 29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4) ts-node: specifier: 10.9.2 version: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) @@ -7274,6 +7317,9 @@ packages: '@types/node@22.5.5': resolution: {integrity: sha512-Xjs4y5UPO/CLdzpgR6GirZJx36yScjh73+2NlLlkFRSoQN8B0DpfXPdZGnvVmLRLOsqDpOfTNv7D9trgGhmOIA==} + '@types/node@22.7.4': + resolution: {integrity: sha512-y+NPi1rFzDs1NdQHHToqeiX2TIS79SWEAw9GYhkkx8bD0ChpfqC+n2j5OXOCpzfojBEBt6DnEnnG9MY0zk1XLg==} + '@types/normalize-package-data@2.4.4': resolution: {integrity: sha512-37i+OaWTh9qeK4LSHPsyRC7NahnGotNuZvjLSgcPzblpHB3rrCJxAOgI5gCdKm7coonsaX1Of0ILiTcnZjbfxA==} @@ -15987,11 +16033,11 @@ snapshots: dependencies: commander: 12.1.0 - '@commitlint/cli@19.4.1(@types/node@22.5.5)(typescript@5.7.0-dev.20241008)': + '@commitlint/cli@19.4.1(@types/node@22.7.4)(typescript@5.7.0-dev.20241008)': dependencies: '@commitlint/format': 19.3.0 '@commitlint/lint': 19.4.1 - '@commitlint/load': 19.4.0(@types/node@22.5.5)(typescript@5.7.0-dev.20241008) + '@commitlint/load': 19.4.0(@types/node@22.7.4)(typescript@5.7.0-dev.20241008) '@commitlint/read': 19.4.0 '@commitlint/types': 19.0.3 execa: 8.0.1 @@ -16038,7 +16084,7 @@ snapshots: '@commitlint/rules': 19.4.1 '@commitlint/types': 19.0.3 - '@commitlint/load@19.4.0(@types/node@22.5.5)(typescript@5.7.0-dev.20241008)': + '@commitlint/load@19.4.0(@types/node@22.7.4)(typescript@5.7.0-dev.20241008)': dependencies: '@commitlint/config-validator': 19.0.3 '@commitlint/execute-rule': 19.0.0 @@ -16046,7 +16092,7 @@ snapshots: '@commitlint/types': 19.0.3 chalk: 5.3.0 cosmiconfig: 9.0.0(typescript@5.7.0-dev.20241008) - cosmiconfig-typescript-loader: 5.0.0(@types/node@22.5.5)(cosmiconfig@9.0.0(typescript@5.7.0-dev.20241008))(typescript@5.7.0-dev.20241008) + cosmiconfig-typescript-loader: 5.0.0(@types/node@22.7.4)(cosmiconfig@9.0.0(typescript@5.7.0-dev.20241008))(typescript@5.7.0-dev.20241008) lodash.isplainobject: 4.0.6 lodash.merge: 4.6.2 lodash.uniq: 4.5.0 @@ -17146,7 +17192,7 @@ snapshots: '@jest/console@29.7.0': dependencies: '@jest/types': 29.6.3 - '@types/node': 22.5.3 + '@types/node': 22.7.4 chalk: 4.1.2 jest-message-util: 29.7.0 jest-util: 29.7.0 @@ -17159,14 +17205,14 @@ snapshots: '@jest/test-result': 29.7.0 '@jest/transform': 29.7.0 '@jest/types': 29.6.3 - '@types/node': 22.5.3 + '@types/node': 22.7.4 ansi-escapes: 4.3.2 chalk: 4.1.2 ci-info: 3.9.0 exit: 0.1.2 graceful-fs: 4.2.11 jest-changed-files: 29.7.0 - jest-config: 29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)) + jest-config: 29.7.0(@types/node@22.7.4)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)) jest-haste-map: 29.7.0 jest-message-util: 29.7.0 jest-regex-util: 29.6.3 @@ -17191,7 +17237,7 @@ snapshots: dependencies: '@jest/fake-timers': 29.7.0 '@jest/types': 29.6.3 - '@types/node': 22.5.3 + '@types/node': 22.7.4 jest-mock: 29.7.0 '@jest/expect-utils@29.7.0': @@ -17209,7 +17255,7 @@ snapshots: dependencies: '@jest/types': 29.6.3 '@sinonjs/fake-timers': 10.3.0 - '@types/node': 22.5.3 + '@types/node': 22.7.4 jest-message-util: 29.7.0 jest-mock: 29.7.0 jest-util: 29.7.0 @@ -17231,7 +17277,7 @@ snapshots: '@jest/transform': 29.7.0 '@jest/types': 29.6.3 '@jridgewell/trace-mapping': 0.3.25 - '@types/node': 22.5.3 + '@types/node': 22.7.4 chalk: 4.1.2 collect-v8-coverage: 1.0.2 exit: 0.1.2 @@ -17301,7 +17347,7 @@ snapshots: '@jest/schemas': 29.6.3 '@types/istanbul-lib-coverage': 2.0.6 '@types/istanbul-reports': 3.0.4 - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/yargs': 17.0.32 chalk: 4.1.2 @@ -18462,7 +18508,7 @@ snapshots: '@slack/logger': 3.0.0 '@slack/types': 2.14.0 '@types/is-stream': 1.1.0 - '@types/node': 22.5.3 + '@types/node': 22.7.4 axios: 1.7.7 eventemitter3: 3.1.2 form-data: 2.5.1 @@ -18909,7 +18955,7 @@ snapshots: '@types/body-parser@1.19.5': dependencies: '@types/connect': 3.4.38 - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/cacheable-request@6.0.3': dependencies: @@ -18929,7 +18975,7 @@ snapshots: '@types/connect@3.4.38': dependencies: - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/content-disposition@0.5.8': {} @@ -18948,7 +18994,7 @@ snapshots: '@types/cors@2.8.17': dependencies: - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/cross-spawn@6.0.2': dependencies: @@ -18964,7 +19010,7 @@ snapshots: '@types/express-serve-static-core@4.19.0': dependencies: - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/qs': 6.9.15 '@types/range-parser': 1.2.7 '@types/send': 0.17.4 @@ -18997,13 +19043,13 @@ snapshots: dependencies: '@types/express': 4.17.21 '@types/koa': 2.15.0 - '@types/node': 22.5.3 + '@types/node': 22.7.4 fs-capacitor: 8.0.0 graphql: 16.9.0 '@types/highland@2.13.0': dependencies: - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/http-assert@1.5.5': {} @@ -19013,7 +19059,7 @@ snapshots: '@types/ioredis-mock@8.2.5': dependencies: - '@types/node': 22.5.5 + '@types/node': 22.7.4 ioredis: 5.4.1 transitivePeerDependencies: - supports-color @@ -19043,7 +19089,7 @@ snapshots: '@types/jsonwebtoken@9.0.6': dependencies: - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/jwk-to-pem@2.0.3': {} @@ -19051,7 +19097,7 @@ snapshots: '@types/keyv@3.1.4': dependencies: - '@types/node': 22.5.5 + '@types/node': 22.7.4 '@types/koa-compose@3.2.8': dependencies: @@ -19066,7 +19112,7 @@ snapshots: '@types/http-errors': 2.0.4 '@types/keygrip': 1.0.6 '@types/koa-compose': 3.2.8 - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/locutus@0.0.8': {} @@ -19086,7 +19132,7 @@ snapshots: '@types/morgan@1.9.9': dependencies: - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/ms@0.7.34': {} @@ -19100,20 +19146,20 @@ snapshots: '@types/mute-stream@0.0.4': dependencies: - '@types/node': 22.5.5 + '@types/node': 22.7.4 '@types/mysql@2.15.26': dependencies: - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/node-fetch@2.6.11': dependencies: - '@types/node': 22.5.3 + '@types/node': 22.7.4 form-data: 4.0.0 '@types/node-fetch@2.6.6': dependencies: - '@types/node': 22.5.3 + '@types/node': 22.7.4 form-data: 4.0.0 '@types/node-gcm@1.0.5': {} @@ -19134,6 +19180,10 @@ snapshots: dependencies: undici-types: 6.19.8 + '@types/node@22.7.4': + dependencies: + undici-types: 6.19.8 + '@types/normalize-package-data@2.4.4': {} '@types/parse-path@7.0.3': {} @@ -19185,12 +19235,12 @@ snapshots: '@types/send@0.17.4': dependencies: '@types/mime': 1.3.5 - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/serve-static@1.15.7': dependencies: '@types/http-errors': 2.0.4 - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/send': 0.17.4 '@types/shimmer@1.0.5': {} @@ -19203,7 +19253,7 @@ snapshots: dependencies: '@types/cookiejar': 2.1.5 '@types/methods': 1.1.4 - '@types/node': 22.5.3 + '@types/node': 22.7.4 '@types/supertest@6.0.2': dependencies: @@ -20631,9 +20681,9 @@ snapshots: object-assign: 4.1.1 vary: 1.1.2 - cosmiconfig-typescript-loader@5.0.0(@types/node@22.5.5)(cosmiconfig@9.0.0(typescript@5.7.0-dev.20241008))(typescript@5.7.0-dev.20241008): + cosmiconfig-typescript-loader@5.0.0(@types/node@22.7.4)(cosmiconfig@9.0.0(typescript@5.7.0-dev.20241008))(typescript@5.7.0-dev.20241008): dependencies: - '@types/node': 22.5.5 + '@types/node': 22.7.4 cosmiconfig: 9.0.0(typescript@5.7.0-dev.20241008) jiti: 1.21.0 typescript: 5.7.0-dev.20241008 @@ -23074,6 +23124,37 @@ snapshots: - babel-plugin-macros - supports-color + jest-config@29.7.0(@types/node@22.7.4)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)): + dependencies: + '@babel/core': 7.24.8 + '@jest/test-sequencer': 29.7.0 + '@jest/types': 29.6.3 + babel-jest: 29.7.0(@babel/core@7.24.8) + chalk: 4.1.2 + ci-info: 3.9.0 + deepmerge: 4.3.1 + glob: 7.2.3 + graceful-fs: 4.2.11 + jest-circus: 29.7.0 + jest-environment-node: 29.7.0 + jest-get-type: 29.6.3 + jest-regex-util: 29.6.3 + jest-resolve: 29.7.0 + jest-runner: 29.7.0 + jest-util: 29.7.0 + jest-validate: 29.7.0 + micromatch: 4.0.7 + parse-json: 5.2.0 + pretty-format: 29.7.0 + slash: 3.0.0 + strip-json-comments: 3.1.1 + optionalDependencies: + '@types/node': 22.7.4 + ts-node: 10.9.2(@types/node@22.5.3)(typescript@5.5.4) + transitivePeerDependencies: + - babel-plugin-macros + - supports-color + jest-diff@29.7.0: dependencies: chalk: 4.1.2 @@ -23115,7 +23196,7 @@ snapshots: dependencies: '@jest/types': 29.6.3 '@types/graceful-fs': 4.1.9 - '@types/node': 22.5.3 + '@types/node': 22.7.4 anymatch: 3.1.3 fb-watchman: 2.0.2 graceful-fs: 4.2.11 @@ -23158,7 +23239,7 @@ snapshots: jest-mock@29.7.0: dependencies: '@jest/types': 29.6.3 - '@types/node': 22.5.3 + '@types/node': 22.7.4 jest-util: 29.7.0 jest-pnp-resolver@1.2.3(jest-resolve@29.7.0): @@ -23193,7 +23274,7 @@ snapshots: '@jest/test-result': 29.7.0 '@jest/transform': 29.7.0 '@jest/types': 29.6.3 - '@types/node': 22.5.3 + '@types/node': 22.7.4 chalk: 4.1.2 emittery: 0.13.1 graceful-fs: 4.2.11 @@ -23221,7 +23302,7 @@ snapshots: '@jest/test-result': 29.7.0 '@jest/transform': 29.7.0 '@jest/types': 29.6.3 - '@types/node': 22.5.3 + '@types/node': 22.7.4 chalk: 4.1.2 cjs-module-lexer: 1.3.1 collect-v8-coverage: 1.0.2 @@ -23267,7 +23348,7 @@ snapshots: jest-util@29.7.0: dependencies: '@jest/types': 29.6.3 - '@types/node': 22.5.3 + '@types/node': 22.7.4 chalk: 4.1.2 ci-info: 3.9.0 graceful-fs: 4.2.11 @@ -23286,7 +23367,7 @@ snapshots: dependencies: '@jest/test-result': 29.7.0 '@jest/types': 29.6.3 - '@types/node': 22.5.3 + '@types/node': 22.7.4 ansi-escapes: 4.3.2 chalk: 4.1.2 emittery: 0.13.1 @@ -24901,7 +24982,7 @@ snapshots: '@protobufjs/path': 1.1.2 '@protobufjs/pool': 1.1.0 '@protobufjs/utf8': 1.1.0 - '@types/node': 22.5.3 + '@types/node': 22.7.4 long: 5.2.3 protocols@2.0.1: {} @@ -25846,7 +25927,7 @@ snapshots: stripe@16.9.0: dependencies: - '@types/node': 22.5.3 + '@types/node': 22.7.4 qs: 6.13.0 striptags@3.2.0: {} @@ -26145,7 +26226,26 @@ snapshots: '@jest/types': 29.6.3 babel-jest: 29.7.0(@babel/core@7.24.5) - ts-jest@29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4): + ts-jest@29.2.5(@babel/core@7.24.8)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.24.8))(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4): + dependencies: + bs-logger: 0.2.6 + ejs: 3.1.10 + fast-json-stable-stringify: 2.1.0 + jest: 29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)) + jest-util: 29.7.0 + json5: 2.2.3 + lodash.memoize: 4.1.2 + make-error: 1.3.6 + semver: 7.6.3 + typescript: 5.5.4 + yargs-parser: 21.1.1 + optionalDependencies: + '@babel/core': 7.24.8 + '@jest/transform': 29.7.0 + '@jest/types': 29.6.3 + babel-jest: 29.7.0(@babel/core@7.24.8) + + ts-jest@29.2.5(@babel/core@7.25.2)(@jest/transform@29.7.0)(@jest/types@29.6.3)(babel-jest@29.7.0(@babel/core@7.25.2))(esbuild@0.23.0)(jest@29.7.0(@types/node@22.5.3)(ts-node@10.9.2(@types/node@22.5.3)(typescript@5.5.4)))(typescript@5.5.4): dependencies: bs-logger: 0.2.6 ejs: 3.1.10 @@ -26163,6 +26263,7 @@ snapshots: '@jest/transform': 29.7.0 '@jest/types': 29.6.3 babel-jest: 29.7.0(@babel/core@7.25.2) + esbuild: 0.23.0 ts-log@2.2.5: {} @@ -26184,6 +26285,24 @@ snapshots: v8-compile-cache-lib: 3.0.1 yn: 3.1.1 + ts-node@10.9.2(@types/node@22.7.4)(typescript@5.5.4): + dependencies: + '@cspotcode/source-map-support': 0.8.1 + '@tsconfig/node10': 1.0.11 + '@tsconfig/node12': 1.0.11 + '@tsconfig/node14': 1.0.3 + '@tsconfig/node16': 1.0.4 + '@types/node': 22.7.4 + acorn: 8.12.1 + acorn-walk: 8.3.2 + arg: 4.1.3 + create-require: 1.1.1 + diff: 4.0.2 + make-error: 1.3.6 + typescript: 5.5.4 + v8-compile-cache-lib: 3.0.1 + yn: 3.1.1 + ts-pattern@4.3.0: {} ts-toolbelt@9.6.0: {} diff --git a/servers/otel-collector/Dockerfile b/servers/otel-collector/Dockerfile new file mode 100644 index 000000000..307698e55 --- /dev/null +++ b/servers/otel-collector/Dockerfile @@ -0,0 +1,21 @@ +# Use an alpine image as our base image, this allows us to define our own entry point script and have access to sh or bash, which the otel image does not have +FROM alpine:3 +RUN apk add nginx curl + +# Copy the otelcol-contrib binary from the official image +COPY --from=otel/opentelemetry-collector-contrib:0.111.0 /otelcol-contrib /otelcol-contrib +COPY otel-collector-config.yaml /etc/otelcol-contrib/config.yaml +COPY httpd.conf /etc/nginx/http.d/default.conf + +COPY entrypoint.sh /entrypoint.sh +RUN chmod a+x /entrypoint.sh + +#Set the ENV variable for the google credentials that will be used by the google cloud exporter and mounted via an environment variable that will be saved to this file via our entrypoint script +ENV GOOGLE_APPLICATION_CREDENTIALS=/etc/otelcol-contrib/key.json +WORKDIR / + +ENTRYPOINT [ "./entrypoint.sh" ] + +EXPOSE 3000 + +CMD [ "/otelcol-contrib", "--config", "/etc/otelcol-contrib/config.yaml" ] \ No newline at end of file diff --git a/servers/otel-collector/entrypoint.sh b/servers/otel-collector/entrypoint.sh new file mode 100644 index 000000000..de4b16bf6 --- /dev/null +++ b/servers/otel-collector/entrypoint.sh @@ -0,0 +1,5 @@ +#!/bin/sh +set -e +echo "$GOOGLE_APPLICATION_CREDENTIALS_JSON" > /etc/otelcol-contrib/key.json +nginx & +exec "$@" \ No newline at end of file diff --git a/servers/otel-collector/httpd.conf b/servers/otel-collector/httpd.conf new file mode 100644 index 000000000..545d6d2dc --- /dev/null +++ b/servers/otel-collector/httpd.conf @@ -0,0 +1,15 @@ +# This is a default site configuration which will simply return 200 and proxy all requests to the upstream collector +server { + listen 3000 default_server; + listen [::]:3000 default_server; + + # Everything is a 200 + location /status { + default_type application/json; + return 200 '{"status": "ok"}'; + } + + location / { + proxy_pass http://localhost:4318; + } +} \ No newline at end of file diff --git a/servers/otel-collector/otel-collector-config.yaml b/servers/otel-collector/otel-collector-config.yaml new file mode 100644 index 000000000..2c1a4b563 --- /dev/null +++ b/servers/otel-collector/otel-collector-config.yaml @@ -0,0 +1,85 @@ +# Note this is only built nightly and will take effect on the next deploy after being built. +receivers: + otlp: + protocols: + # Disabling GRPC until we take the time to do it in a good way in our AWS environment. (Mainly we need to update our TF Modules to support it and create a proxy that has a health check for the ALB, theres a few github issues on OTELs repo for this.) + # grpc: + # endpoint: "0.0.0.0:4317" # gRPC port for receiving traces, metrics, and logs over gRPC + http: + endpoint: '0.0.0.0:4318' # http port for receiving traces, metrics, and logs over http + +exporters: + googlecloud: + log: + default_log_name: opentelemetry.io/collector-exported-log + # debug: + # verbosity: detailed +processors: + memory_limiter: + check_interval: 1s + limit_percentage: 70 + spike_limit_percentage: 10 + batch: + # batch metrics before sending to reduce API usage + send_batch_max_size: 10100 + send_batch_size: 10000 + timeout: 5s + resourcedetection/ecs: + detectors: [env, ecs] + timeout: 2s + # Ensures that anything coming from the ECS detector in code will not override any existing attributes. + # Otherwise, note, that the ECS detector will be that of where the collector is running, not the service. + override: false + resource/cleanup_for_google: + attributes: + - key: service.namespace + value: pocket + action: insert + # We must set the region to us-east1, as the google exporter uses this to know where to send data to. + - key: cloud.region + value: us-east1 + action: upsert + - key: cloud.availability_zone + value: us-east1-b + action: upsert + # set this to the ecs task id + - key: host.id + from_attribute: aws.ecs.task.id + action: upsert + # https://opentelemetry.io/docs/specs/semconv/resource/deployment-environment/ + - key: deployment.environment.name + value: ${env:DEPLOYMENT_ENVIRONMENT_NAME} + action: upsert + +service: + pipelines: + traces: + receivers: [otlp] + processors: + [ + resourcedetection/ecs, + resource/cleanup_for_google, + memory_limiter, + batch, + ] + exporters: [googlecloud] + metrics: + receivers: [otlp] + processors: + [ + resourcedetection/ecs, + resource/cleanup_for_google, + memory_limiter, + batch, + ] + exporters: [googlecloud] + logs: + receivers: [otlp] + processors: + [ + resourcedetection/ecs, + resource/cleanup_for_google, + memory_limiter, + batch, + ] + exporters: [googlecloud]