Perl - Dockerfile Publish Failures
メンテナーはふだん 1 日以内に返信
関連するプルリクエストがすでにマージされています。
- #2402 @Omnideth による — マージ済み
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 58/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 領域
- build-system, devops
調査の方向性
Start with the cpanm and Carton Dockerfile generators in src/CommunityToolkit.Aspire.Hosting.Perl/PerlAppResourceBuilderExtensions.Dockerfile.cs, then read HasDependencyFiles in src/CommunityToolkit.Aspire.Hosting.Perl/PerlAppResourceBuilderExtensions.cs to compare publish behavior with run mode. Trace how WithPackage(...) modules and cartonDeployment are represented, then inspect the related tests. Done means the listed manifest and package cases generate images that build and include their dependencies.
索引モデルが issue の本文から書いたものです。
説明
Describe the bug
Both Dockerfile generators emit COPY lines for dependency manifests without checking that the files exist:
- cpanm (PerlAppResourceBuilderExtensions.Dockerfile.cs#L167):
COPY cpanfile ./ - Carton (#L215-L216):
COPY cpanfile ./andCOPY cpanfile.snapshot ./. The snapshot is copied even when
WithProjectDependencies(cartonDeployment: false)is used, where it's optional.
docker build fails with "/cpanfile": not found for:
- any Perl app with no
cpanfile, including a plainAddPerlScriptwith no dependencies, which is the
default publish path (the cpanm generator is the fallback for every resource); - apps that declare dependencies through
Makefile.PL/Build.PLonly. Run mode supports these
(HasDependencyFiles),
but publish doesn't; - Carton apps without a snapshot, when
cartonDeployment: false.
A related gap: modules declared only through WithPackage(...) are never installed in the image, so an
app that publishes successfully can still fail at runtime with Can't locate Foo/Bar.pm.
Regression
No response
Steps to reproduce
1. Create an app directory with only `app.pl`, and no `cpanfile`.
2. `builder.AddPerlScript("app", "../app", "app.pl");`
3. `aspire publish`, then build the generated Dockerfile.
Expected behavior
- No manifest: no dependency
COPY/ install step, and the image builds. Makefile.PL/Build.PLonly: copy them and runcpanm --installdeps --notest ..- Carton: copy
cpanfile.snapshotonly if it exists; require it only whencartonDeploymentistrue. WithPackagemodules: install them withcpanm --notest <Module> ...in the image (respecting
local::lib), after project dependencies.
Screenshots
No response
IDE and version
VS Code
IDE version
No response
Nuget packages
Additional context
No response
Help us help you
Yes, I'd like to be assigned to work on this item
- 主要言語
- C#
- スター
- 632
- フォーク
- 204
- 平均マージ
- 2日 13時間
- マージ済み PR(30日)
- 92
環境構築
このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
CommunityToolkit/Aspire のほかの issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
CommunityToolkit/Aspire#1622 · コメント 6 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
CommunityToolkit/Aspire#1620 · コメント 6 件 ·
メンテナーはふだん 1 日以内に返信
-
integration request :mailbox_with_mail:
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
CommunityToolkit/Aspire#2424 ·
メンテナーはふだん 1 日以内に返信
-
Update Toolkit to Aspire 17.1 nightly 17.1.0-preview.1.26556.8対応中かも @aaronpowell が 1 日前に担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 1/100
CommunityToolkit/Aspire#2421 ·
メンテナーはふだん 1 日以内に返信
-
難易度 3/5 1〜2日 初心者へのやさしさ 66/100
CommunityToolkit/Aspire#2420 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
CommunityToolkit/Aspire の issue をすべて見る
似ている issue
-
area:build type:chore
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
-
python triage
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
microsoft/semantic-kernel#14753 ·
メンテナーはふだん 5 日以内に返信
-
NEW ISSUE Requestor-Player
難易度 2/5 1〜3時間 初心者へのやさしさ 81/100
tModLoader/tModLoader#5575 · リアクション 1 件 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
A: Art Beginner Friendly P3: Standard T: Bugfix
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
space-wizards/space-station-14#46728 ·
メンテナーはふだん 1 日以内に返信