chore: scaffold from seamless-templates v0.5.0 - #143
Merged
Conversation
v0.5.0 declares the {{databaseUrl}} placeholder and ships the express starter's
DATABASE_URL and TLS support, so bumping the ref is what makes the managed
bundled database wiring take effect.
Verified against the published tag rather than a fixture: the manifest declares
DATABASE_URL, a managed context writes the full placeholder connection string
into api/.env, a local context writes an empty value so the starter falls back
to its DB_* variables, and src/lib/databaseUrl.ts is present in the copied
template.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bumps
SEAMLESS_TEMPLATES_REFfromv0.4.0tov0.5.0, the release that carries the expressstarter's
DATABASE_URLand TLS support (fells-code/seamless-templates#22).This is the step that makes #141 take effect. The CLI already computed the managed connection string,
but
applyTemplateEnvonly writes keys the manifest declares, andv0.4.0did not declare{{databaseUrl}}, so nothing was written.Verified against the published tag
Not a fixture: I ran the real
openTemplateSourceatv0.5.0, copied the express starter into tempdirectories, and applied
applyTemplateEnvwith both scaffold contexts.DATABASE_URL: {{databaseUrl}}.DATABASE_URL=postgres://USER:PASSWORD@db.example.com:5432/tenant?sslmode=require.DATABASE_URL=, so the starter falls back to its discreteDB_*values, asthe compose stack needs.
src/lib/databaseUrl.tsis present in the copied template.That empty-local case was the one that could have broken the existing flow: an unresolved placeholder
throws, so a missing
databaseUrlon the local path would have failed every local scaffold.npm run buildandnpm testpass (691 passed, 4 skipped), coverage unchanged at 99.37% lines.Still open
cliMinin the templates manifest is still0.10.0. Raising it needs another templates release andbuys little, since the CLI only ever fetches the ref it pins. Worth folding into the next templates
change rather than releasing for it alone.
The TLS certificate question stands: if a tenant's Postgres presents a certificate that does not chain
to a public CA, managed connections fail until
DB_SSL_REJECT_UNAUTHORIZED=falseis set. First livetrial will tell us, and if it does not chain we should ship the CA rather than flip the default.