Repository navigation
feat: create_site takes a kind for redirect hosts - #39
Merged
Merged
Conversation
The instructions and the site and deploy tool descriptions cover redirect hosts, and the deploy tools pass RedirectHostHasNoFiles through. Needs the SDK release with kind on sites.create.
create_site's description already gives the custom-domain rule, the cap and the errors.
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.
Summary
create_sitetakeskind. Withkind: "redirect"it creates a redirect host: a hostname on one of the organization's own custom domains that serves only its redirect rules, set afterwards withset_redirectsoradd_redirect. A redirect host takes no files and doesn't count toward the plan's site limit; an organization can have up to 50.create_site's description, to keep the instructions short.create_siteexplains the kind, the custom-domain rule and the bare apex throughwww;list_sitesnameskind;deploy_filesanddeploy_create_uploadsay a redirect host answersRedirectHostHasNoFiles.CustomDomainRequired(409) on a shared domain,RedirectHostLimitReached(403) at the cap, andRedirectHostHasNoFiles(409) from the deploy tools.New tests in
test/redirectHosts.test.tscover thekindschema, the request body with and withoutkind, and both refusals passing through.Dependency. Requires
@hostsmith/sdk1.6.0, released from hostsmith/js-sdk#17, forkindonsites.create. The API side is hostsmith/hostsmith#335, deployed to dev.Instructions length.
npm run smokereports the instructions at 5,033 characters against its 4,000 target. Main is already at about 4,750, and this adds about 280. CI doesn't run the smoke script.Type of change
fix:bug fixfeat:new featurefeat!:/BREAKING CHANGE:breaking changedocs:/chore:/refactor:/test:/perf:non-shippingChecklist
npm run typecheckpassesnpm run buildpassesdeploy_filesto a redirect host answeredAPI error 409 (RedirectHostHasNoFiles), andget_siteshowedkind: "redirect".create_sitewithkindneeds this release.