Static sites
A static site is an app that serves HTML, CSS and JavaScript files and runs no code of its own. Astris builds it from a Git repository and serves the files on port 80.
Create a static site
The MCP tool deploy takes build set to static. It also takes publish_directory, the directory to publish, and spa, for a single-page app. With the CLI, add these flags to astris deploy:
--build static--publish-directory <dir>, the directory to publish--spa, to serve the directory as a single-page app
astris deploy --project <project> --name <app> --git-url <repository> --branch <branch> --build static --publish-directory <dir>The port is ignored for a static site. --spa takes no value.
Rules
--publish-directoryand--spaneed--build static.- A static site cannot use
--dockerfile. - A worker or a cron app cannot be a static site.
- The build is set when you create the app.
The CLI refuses a call that breaks a rule and sends nothing. The API refuses it with bad_request.
Address
A static site is a web app, so it can have an address on astris.live or a hostname you own. See Domains.
Your plan's pool
A static site counts against your plan's pool like any app. See Usage.
