CI/CD: optional GITHUB_TOKEN for composer, functional tests never send email, registry secret apply (template !12)
还没有人认领这个 Issue。
评估
- 难度
- 3/5
- 预计耗时
- 1-2 天
- 新手友好度
- 58/100
- Issue 类型
- 文档
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- docker, github-actions, helm, kubernetes, php
- 领域
- ci-cd, devops, documentation
调研方向
Update content/6.deployment/3.ci-cd.md, especially the variables table at line 73, the bin/devops/setup.sh section around line 147, and run_test_functional around line 167; compare with content/6.deployment/1.docker.md at line 224. Document the token, email-safe test setup, registry secret, Helm defaults, removed VARNISH_TOKEN, and stale GitHub deploy statement using the issue details. Done when the CI/CD guide consistently describes these behaviors and no longer lists the unused variable.
由索引模型根据 Issue 内容生成。
描述
Template MR !12 (components-web-app#123, merged as 1a530d4) changed CI in ways content/6.deployment/3.ci-cd.md should cover.
1. Optional GITHUB_TOKEN for composer (new row in the variables table, plus a note in the bin/devops/setup.sh section, line 147)
- Without it, composer's ~180 downloads from github.com are anonymous: 60 requests an hour per IP. On a shared runner, installs fail part way through with a 429.
- A fine-grained token with no permissions is enough.
setup.shturns it intoCOMPOSER_AUTHand setsCOMPOSER_MAX_PARALLEL_HTTP=6. Unset stays unset (an empty token is rejected outright, which is worse than anonymous). build_apipasses it to the API image build as thecomposer_authbuild secret, never a build arg, so it stays out of the image history. The build log'sgithub rate limit for this build:line prints 60 (anonymous) or 5000 (token applied).- GitHub Actions maps its own
secrets.GITHUB_TOKENon the build step, so nothing needs setting there. - Keep this consistent with
content/6.deployment/1.docker.md:224, which already mentionsGITHUB_TOKENfor localcomposer update.
2. Functional tests never send real email (the functional tests row at line 73, and run_test_functional at line 167)
- Every CI variable reaches the test job, and a real environment variable beats
api/.env.test, so a project's liveMAILER_DSNwould deliver any email a test sends (a contact form, a password reset). run_test_functionalunsetsMAILER_DSNandMAILER_EMAIL, andapi/.env.testsetsMAILER_DSN=null://null: mail is built and Symfony's mailer assertions still see it, but nothing is delivered. Both halves are needed: without the.env.testline, tests fall back to.env'ssmtp-relayhost, which CI doesn't have, and error.- The job also generates a test JWT keypair (
lexik:jwt:generate-keypair --skip-if-exists), so tests that sign in work in CI.
3. Smaller changes
- The registry pull secret is now
kubectl applyd, notreplace --forced (concurrent releases in one namespace raced with "already exists"). The first deploy after the change prints a harmless one-off warning about a missinglast-applied-configurationannotation. helm lintandhelm templatenow pass on the chart's own defaults (jwt-passphrasedefaults to"").VARNISH_TOKEN(chartapiSecretToken) is gone: nothing read it. If the docs list it anywhere, remove it.
While there, unrelated: line 416 says "GitHub deploys don't pass these variables" (MAILER_DSN, MAILER_EMAIL, ORPHAN_SCAN*), but line 411 says they do. Since template #102 they do, so 416 looks stale.
- 主要语言
- Vue
- 星标
- 0
- 派生
- 0
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
这个项目没有提供开发容器、Dockerfile 或贡献指南,环境需要你自己搭建:先看它的 README,通用步骤见我们的新手贡献指南。
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
components-web-app/docs 的其他 Issue
-
Website: the docs site's own service worker can't install (navigateFallback "/" isn't precached)未关闭bug
难度 2/5 1-3 小时 新手友好度 70/100
components-web-app/docs#173 ·
-
bug
难度 2/5 1-3 小时 新手友好度 82/100
components-web-app/docs#169 ·
-
bug
难度 2/5 1-3 小时 新手友好度 78/100
components-web-app/docs#152 ·
-
enhancement
难度 3/5 1-2 天 新手友好度 55/100
components-web-app/docs#179 ·
-
enhancement
难度 4/5 3-5 天 新手友好度 48/100
components-web-app/docs#178 ·
查看 components-web-app/docs 的全部 Issue
相似的 Issue
-
lens:agent lens:process process
难度 2/5 1-3 小时 新手友好度 78/100
thebristolsound/birdbrain#1771 ·
维护者通常 1 天内回复
-
ci-install-db-tools stall-case tests flake: stalled apt-get can be killed before it logs its call未关闭effort:low model:light plan planner:opus-5-5 tests
难度 2/5 1-3 小时 新手友好度 86/100
维护者通常 1 天内回复
-
component/test-automation work/tech-debt
难度 2/5 1-3 小时 新手友好度 78/100
bcgov/bc-wallet-mobile#4845 ·
维护者通常 1 天内回复
-
first
难度 2/5 1-3 小时 新手友好度 72/100
AcademySoftwareFoundation/rmtc#54 · 1 条评论 ·
-
难度 2/5 1-3 小时 新手友好度 72/100
stac-utils/stac-fastapi-elasticsearch-opensearch#932 ·
维护者通常 1 天内回复