Add programmatic configuration
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 初心者へのやさしさ
- 45/100
- issue の種類
- 機能追加
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 技術スタック
- docker, node.js, typescript
- 領域
- tooling
調査の方向性
Start with packages/testcontainers/src/test-containers.ts and packages/testcontainers/src/testcontainers-runtime/strategies/utils/config.ts, then trace the listed process.env reads in the reaper, port forwarder, image name, generic container and auth paths. Define how configuration is resolved alongside environment variables and the properties file, including precedence and changes after runtime initialization. Done means TestContainers.configure() and getConfiguration() provide typed effective settings while existing configuration sources continue to work.
索引モデルが issue の本文から書いたものです。
説明
What happens
Configuration comes only from environment variables and .testcontainers.properties, and each setting is read where it is used. Fourteen variables are read through process.env across packages/testcontainers/src (Ryuk image, port, privileged, verbose and disabled flags, the SSHD image and port, the hub image prefix, reuse, Docker auth config and others), plus the Docker host settings in the strategy config.
- Changing a setting from code means assigning to
process.envbefore the first container starts. - Nothing is typed or validated. A misspelt variable is silently ignored.
- There is no way to read the effective configuration.
Expected
A typed configuration object with one place that resolves it:
TestContainers.configure({
ryuk: { disabled: false, privileged: true },
hubImageNamePrefix: "registry.example.com/mirror",
reuse: { enabled: true },
});
- Environment variables and the properties file keep working, with a documented precedence.
TestContainers.getConfiguration()returns what is in effect.
Where
packages/testcontainers/src/container-runtime/strategies/utils/config.ts- the
process.envreads inreaper/reaper.ts,port-forwarder/port-forwarder.ts,container-runtime/image-name.ts,generic-container/generic-container.tsandcontainer-runtime/auth/ packages/testcontainers/src/test-containers.ts
Notes
- Java centralises this in
TestcontainersConfiguration. - Configuration must be set before the runtime client and Ryuk are created. Decide what happens when it is changed afterwards.
Dependencies
- Nothing blocks this. It can start now.
- Coordinate with #1568: the logger is a natural configuration setting.
- 主要言語
- TypeScript
- スター
- 2.6k
- フォーク
- 274
- 平均マージ
- 1日 14時間
- マージ済み PR(30日)
- 44
環境構築
このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。
- Dockerfile または Docker Compose ファイルあり
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
testcontainers/testcontainers-node のほかの issue
-
enhancement minor
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
testcontainers/testcontainers-node#1539 ·
メンテナーはふだん 1 日以内に返信
-
enhancement minor
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
testcontainers/testcontainers-node#1533 ·
メンテナーはふだん 1 日以内に返信
-
enhancement minor
難易度 2/5 1〜3時間 初心者へのやさしさ 77/100
testcontainers/testcontainers-node#1531 ·
メンテナーはふだん 1 日以内に返信
-
enhancement minor
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
testcontainers/testcontainers-node#1529 ·
メンテナーはふだん 1 日以内に返信
-
enhancement minor
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
testcontainers/testcontainers-node#1528 ·
メンテナーはふだん 1 日以内に返信
testcontainers/testcontainers-node の issue をすべて見る
似ている issue
-
documentation good first issue hacktoberfest help wanted
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
libredb/libredb-studio#1756 ·
メンテナーはふだん 1 日以内に返信
-
state:triage-needed
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
メンテナーはふだん 1 日以内に返信
-
community first-timers-only good first issue hacktoberfest help wanted low hanging fruit up-for-grabs
難易度 1/5 1時間未満 初心者へのやさしさ 72/100
lingdojo/kana-dojo#32365 · コメント 1 件 · リアクション 5 件 ·
メンテナーはふだん 1 日以内に返信
-
friction
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
kentcdodds/kody#3706 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
copperheadhq/copperhead#378 ·
メンテナーはふだん 1 日以内に返信