Skip to content

feat(pages): serve the installer at objectfs.io/install.sh (#138) - #440

Merged
scttfrdmn merged 1 commit into
mainfrom
feat/serve-install-script-from-apex
Aug 14, 2026
Merged

scttfrdmn merged 1 commit into
mainfrom
feat/serve-install-script-from-apex

Conversation

@scttfrdmn

Copy link
Copy Markdown
Owner

First half of #138 part (c), per the decision to use GitHub Pages as the hosting surface. This part needs no signing-key decision, so it lands on its own.

What this fixes

curl -fsSL https://objectfs.io/install.sh | bash is the one-liner #138's acceptance criteria name. For that issue's whole life the address answered with a 404: first because objectfs.io served nothing at all, then — once Pages was on — because pages.yml published web/ and the MkDocs tree and no installer. README.md and the landing page pointed at raw.githubusercontent.com/scttfrdmn/objectfs/main/scripts/install.sh instead, which works and is not a URL anyone types from memory.

Copied, not committed

The obvious way to serve a file from a static site is to commit it under the published directory. That is the wrong way here, and it is the whole risk in this change:

every existing gate in internal/config reads scripts/install.sh — the platform mapping against release.yml's matrix, the checksum refusals, the preflight ordering, the landing page's flag coupling. A served copy that differs from it means the file users pipe into bash is the file nothing tests.

So the workflow copies it at build time and cmps the two, and internal/config/served_install_script_test.go asserts three things:

  • the workflow copies the script and compares it byte for byte (presence is not the property that matters)
  • scripts/install.sh is in the paths: filter, so editing the installer redeploys the site
  • no committed duplicate exists at web/install.sh, docs/install.sh or web/scripts/install.sh

A fourth check couples the documented one-liners in README.md and web/index.html to an address that is actually served — the two that work — because every other name under objectfs.io resolves (Porkbun answers a wildcard) and serves nothing. get.objectfs.io opened the getting-started guide for a year on exactly that basis.

Verification

All six mutations fail the intended check with the intended message:

mutation result
remove the cp step FAIL, names the 404
replace the cmp with a no-op FAIL, names the untested-copy risk
remove the paths: entry (cp/cmp still name the path) FAIL, names the silent staleness
commit web/install.sh FAIL, names the shadowing
point README at get.objectfs.io/install.sh FAIL, names the wildcard
delete README's one-liner FAIL, says the check is now vacuous

The paths assertion matches a whole YAML sequence entry rather than a substring, for two reasons found rather than predicted: the path also appears in the cp and cmp commands, so a Contains would pass on a workflow with no trigger for the file; and pre-commit's pretty-format-yaml unquotes and dedents every block sequence in this file, so the first version — asserting 'scripts/install.sh' — would have been failed by the formatter.

The assemble step was also run locally against a real _site tree rather than read: cp, chmod, cmp and the CNAME grep all behave.

Deliberately not in this PR

README.md and web/index.html still point at raw.githubusercontent.com. They get pointed at the new address once it is verified to answer on the deployed site — not before. A documented URL that 404s is the exact defect class this repository has spent several PRs removing, and doing it in this order means the fix is measured rather than assumed.

Still outstanding on part (c), and needing a decision rather than code: where the GPG signing key lives (Actions secret, hardware token, KMS), who can use it, and rotation. The apt/yum repository metadata cannot be built without answering that.

Refs #138

`curl -fsSL https://objectfs.io/install.sh | bash` is the one-liner #138's
acceptance criteria name, and for that issue's whole life the address answered
with a 404 — first because objectfs.io served nothing, then, once Pages was on,
because pages.yml published web/ and the MkDocs tree and no installer. README.md
and the landing page pointed at raw.githubusercontent.com instead, which works
and is not a URL anyone types from memory.

Served by copying scripts/install.sh to the site root at build time, not by
committing a second copy under web/. That distinction is the whole risk here:
every existing check in internal/config reads scripts/install.sh — the platform
mapping against release.yml's matrix, the checksum refusals, the preflight
ordering, the landing page's flags — so a served copy that differs from it means
the file users pipe into bash is the file nothing tests. The workflow therefore
cmp's the two, served_install_script_test.go asserts both the copy and the
comparison, and a third check refuses a committed duplicate at web/install.sh,
docs/install.sh or web/scripts/install.sh.

scripts/install.sh also joins the workflow's paths: filter, which it was not in.
Without that the site keeps serving whichever copy was current at the last docs
change, and nothing is visible: the repository's copy is correct, every check is
green, and the served one is stale.

The paths assertion matches a whole YAML sequence entry rather than a substring,
for two reasons found rather than predicted. The path also appears in the cp and
cmp commands, so a Contains check would pass on a workflow with no trigger for
the file at all. And pre-commit's pretty-format-yaml unquotes and dedents every
block sequence in this file — the first version asserted 'scripts/install.sh'
and the formatter would have failed it.

All six mutations fail the intended check with the intended message. The assemble
step was also run locally: cp, chmod, cmp and the CNAME grep against a real
_site tree.

README.md and the landing page are deliberately unchanged in this commit. They
get pointed at the new address once it is verified to answer, not before — a
documented URL that 404s is the exact defect class this repository has spent
several PRs removing.
@scttfrdmn scttfrdmn added type: enhancement New feature or improvement to existing functionality priority: high Important issue that should be addressed soon area: ci-cd CI workflows, gates, and release automation area: docs Documentation content and structure labels Aug 14, 2026
@scttfrdmn
scttfrdmn merged commit a7a3805 into main Aug 14, 2026
46 checks passed
@scttfrdmn
scttfrdmn deleted the feat/serve-install-script-from-apex branch August 14, 2026 18:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: ci-cd CI workflows, gates, and release automation area: docs Documentation content and structure priority: high Important issue that should be addressed soon type: enhancement New feature or improvement to existing functionality

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant