Repository navigation
Docs: Position Currencyinfo as a universal open-source rates service - #53
Conversation
This script checks for broken links and missing anchors in Markdown files across the repository, including `README.md`, `CONTRIBUTING.md`, and documentation pages. It ensures that links to both internal and external resources are valid, enhancing the reliability of documentation. The tool is designed to run in CI environments without dependencies, providing immediate feedback on documentation integrity.
dev-adamant-im
left a comment
There was a problem hiding this comment.
What works well
- The PR consistently positions Currencyinfo as a universal self-hosted product while keeping ADAMANT visible as a production adopter and maintainer
- The documentation is broad, navigable, and closely aligned with the provider behavior delivered by #49
- The new workflows use narrow permissions, keep pull-request jobs read-only, and gate release publication on membership in
master - The container remains non-root, excludes
config.jsonc, and starts successfully from the shipped defaults against a clean MongoDB database - No runtime source files or production dependency versions are changed
Needs attention
Six inline findings need changes before merge: one release-tagging issue and five documentation, workflow, or dependency issues. The most consequential problem is that docker/metadata-action can still generate latest implicitly, bypassing the explicit newest-release decision.
The PR also contains Closes #50, while the documentation URL and GHCR package currently return 404. Issue #50 explicitly requires both public surfaces and their live verification, so it should remain open until the Pages deployment and first release-driven container publication have completed and the package is public.
Dependency modernization and the documentation toolchain advisories are tracked in #54.
Findings summary
- [P1] Disable
metadata-actionautomaticlatestgeneration so only the guarded raw tag can move it - [P2] Replace the public Compose port mapping instead of appending a loopback mapping
- [P2] Document the required 4.1.2 configuration migration before claiming in-major compatibility
- [P2] Replace the vulnerable Vite and esbuild versions introduced through VitePress
- [P2] Keep
chmodprivileged after changing the configuration file owner - [P2] Run the documentation link workflow when any checked Markdown file or the checker itself changes
Validation performed
pnpm test --runInBand: 28 suites and 266 tests passed- ESLint,
pnpm run format:check,pnpm run build,pnpm run docs:build,pnpm run docs:links, andgit diff --checkpassed - The ARM64 production image built locally and ran as UID 1000 without an embedded
config.jsonc - A clean MongoDB 8.0 smoke test reached
ready: true, fetched from 5/5 default sources, and returned positive BTC, ETH, and ADM rates - Local documentation rendering, navigation, and search worked
- Both GitHub pull-request checks passed on the reviewed head
|
All six inline findings are addressed, and the threads are resolved.
On
|
| Command | Result |
|---|---|
pnpm install --ignore-scripts --frozen-lockfile |
Lockfile up to date |
pnpm test |
28 suites, 266 tests passed |
pnpm run lint |
Clean |
pnpm run format:check |
All matched files use Prettier code style |
pnpm run build |
TSC found 0 issues, 67 files compiled |
pnpm run docs:build |
Built on Vite 8.2.2, no dead internal links |
pnpm run docs:links |
40 Markdown files checked, all links and anchors resolve |
pnpm audit |
2 advisories, both pre-existing qs findings under @nestjs/platform-express |
git diff --check |
Clean |
Two findings were checked against the code rather than taken at face value, and both reproduced exactly as reported:
- the stock 4.1.2 template fails the 4.2.0 schema with precisely the two
api_keyerrors, before the HTTP port opens. The documented migration steps were then validated in the other direction, confirming that both the minimal path and the full one parse - the Vite and esbuild advisories have no patched 5.x line, which is why this is an upgrade rather than an override
The container build and smoke test still run in CI rather than locally, since no Docker daemon is available in the environment this branch is prepared in.
…umentation for Node.js version requirements
…uction image security
Description
Positions Currencyinfo as a universal open-source rates service rather than an ADAMANT-internal component, and builds the distribution surfaces that positioning needs. ADAMANT stays visible as a production adopter and as the maintainer.
No runtime code is touched.
src/is unchanged, and the only new executable is a dependency-free Markdown link checker.Product positioning
README.mdrewritten: universal self-hosted rates service first, ADAMANT as adopter and maintainer, prominent links to the landing page, documentation, releases and container package. All Wiki links removedpackage.json: new description,homepagemoved tohttps://currencyinfo.dev, keywords aligned with the repository topics,docs:*scripts. Staysprivate, since the distributable artifact is the container imageAGENTS.md: mission and positioning rewritten, new Documentation Policy with a table of what must be updated together, Product Surfaces section, documentation commands added to the validation baselineCONTRIBUTING.md: current connector list, a Documentation section, and an "Adding a rate source" checklistLICENSE: canonical GNU GPL v3 text added, so GitHub detects the licenseDocumentation site
A VitePress site in
docs/, published tohttps://currencyinfo.docs.adamant.im. Twenty pages covering overview and positioning, architecture, Docker-first quick start, installation, upgrade and rollback, rate calculation, history and storage, notifications, operations, security, troubleshooting, the REST API, a complete configuration reference synchronized withconfig.default.jsoncandsrc/global/config/schema.ts, and one page per connector.Local search, responsive navigation, edit-on-GitHub links, canonical metadata, a sitemap, and no analytics or third-party telemetry.
CI/CD
docs-check.ymlbuilds the site on pull requests and holds onlycontents: read, so it cannot deploydocs-deploy.ymldeploys to GitHub Pages frommasterand from published releases, verifies the release tag is an ancestor ofmaster, grantspages: writeandid-token: writeonly to the deploy job, and reports thegithub-pagesenvironment URLpublish-docker.ymlpublishesghcr.io/adamant-im/currencyinfoon release only, forlinux/amd64andlinux/arm64, with semantic plus major and minor tags, OCI labels, build cache, provenance and an SBOM.latestmoves only for the newest non-prereleasedocker-ci.ymlbuilds the image on pull requests and smoke-tests it without pushing: it asserts the OCI labels, asserts noconfig.jsoncis baked into a layer, starts MongoDB and the service from the shippedconfig.default.jsonc, confirms non-root execution, and retrieves a rate. No provider credentials are usedContainer packaging
Dockerfile: OCI source, revision, version, description, license and documentation labels; the builder stage is pinned to$BUILDPLATFORMbecause the compiled output is architecture independent; still non-root with no configuration baked indocker-compose.prod.yaml: pulls the published image by default, keeps a commented local-build override for contributors, and pins MongoDB to a supported major versiondocker-compose.yaml: MongoDB pinned to8.0instead oflatestWiki migration
All seven Wiki pages were inventoried, migrated, and corrected.
.github/wiki/holds the replacement tombstones and the publishing procedure. The tombstones are already live: every original slug still resolves and points at its canonical destination.Corrections made during migration, all of which were wrong on the Wiki:
groupPercentagewas documented backwards. It is the minimum relative distance between the weights of the two heaviest groups, not the share of sources a group must contain36668instead of36661, andrateLiftimeinstead ofrateLifetimeSaved rates formatclaimed USD is the only default base coin, while the template configures sevenData source banner
.github/banner-{light,dark}.pngregenerated for the current connector set: the five keyless defaults on the top row, the key-gated ones plus the deprecated CryptoCompare below. Currency API ships no logo, so its mark is drawn from the banknotes-on-a-line photo in that project's own README.Related issue
Refs #50 — deliberately not a closing keyword.
#50 requires the documentation site and the container package to be live and verified, and neither is yet: the Pages deployment needs
docs-deploy.ymlonmaster, and the first image needs a release. Merging this should not auto-close the issue; close it by hand oncehttps://currencyinfo.docs.adamant.imserves over HTTPS andghcr.io/adamant-im/currencyinfois publicly pullable.Builds on #49, whose connector set, configuration schema and defaults are the source of truth for everything documented here.
Partially addresses the documentation toolchain half of #54, see the VitePress note below.
Breaking changes
None for the service.
src/is unchanged, and the REST API, configuration schema, rate calculation and stored document layout are untouched. The only change toconfig.default.jsoncis a comment that pointed at the Wiki and now points at the documentation site.Two changes affect deployments that use the shipped Compose files:
docker-compose.prod.yamlnow pullsghcr.io/adamant-im/currencyinfo:latestinstead of building from the checkout. Contributors who want a local build uncomment thebuildblock that ships with it8.0in both Compose files instead of trackinglatest. An existingmongo_datavolume created by a newer MongoDB will not start under an older serverHow to test
pnpm install --ignore-scripts --frozen-lockfile pnpm run deps:setup pnpm test pnpm run lint pnpm run format:check pnpm run build pnpm run docs:build pnpm run docs:linksdocs:buildfails on a dead link inside the site.docs:linkschecks relative links and heading anchors across every Markdown file in the repository, and resolves links to the published documentation URL against the localdocs/tree, so a brokenREADME.mdlink fails here rather than after deployment.Results on
601d31c:pnpm install --ignore-scripts --frozen-lockfilepnpm testpnpm run lintpnpm run format:checkpnpm run buildpnpm run docs:buildpnpm run docs:linksgit diff --checkThe container build and smoke test were not run locally, because no Docker daemon was available in the environment the branch was prepared in.
docker-ci.ymlruns them on this pull request.To read the site locally:
To exercise the container path the same way
docker-ci.ymldoes:Notes for reviewers
Already done outside this diff
https://currencyinfo.dev, and fifteen topics are setcurrencyinfo.docs.adamant.im, Let's Encrypt certificate issued, Enforce HTTPS on. The site 404s untildocs-deploy.ymlreachesmaster, because the workflow only exists on this branch200. The Wiki is deliberately left enabled so inbound deep links keep resolvingStill to do after merge
The container package does not exist yet:
publish-docker.ymlfires on a published release, so the first image needs av4.2.0release frommaster. Until then, the links toghcr.io/adamant-im/currencyinfoinREADME.mdand the documentation resolve to a 404, and the package must be made public and connected to the repository once it is first published.Issue #50 stays open until both public surfaces are live and verified.
Worth a second opinion
package.jsonstill declaresGPL-3.0, which SPDX deprecated in favour ofGPL-3.0-onlyandGPL-3.0-or-later. Choosing between them is a licensing decision, so the string was left as it was, consistently acrosspackage.json, the container label and the documentation footercryptocompare.comno longer serves brand assets and the product is being folded into CoinDesk Data. The mark the repository already used in that slot was kept2.0.0-alpha.20, taken to clear three Vite and esbuild advisories that have no patched 5.x line.Adamant-im/adamant-consolealready ships a 2.x alpha, so this follows existing practice, but it is an alpha on the canonical documentation site and worth an explicit opinionChecklist
.markdownlint.jsoncand the writing style inAGENTS.mdconfig.default.jsoncandsrc/global/config/schema.tspnpm test,pnpm run lint,pnpm run format:checkandpnpm run buildpasspnpm run docs:buildandpnpm run docs:linkspassgit diff --checkpassesdevelopand references the issue with a closing keywordscripts/check-docs-links.mjsis exercised bydocs-check.ymlon every documentation pull request🤖 Generated with Claude Code