shipsite CLI and GitHub Action

The shipsite CLI deploys a folder of static files to shipsite.sh with one command and prints the live URL. The GitHub Action does the same from a workflow.

shipsite CLI

The CLI is the shipsite npm package. It needs Node.js and nothing else:

export SHIPSITE_API_KEY=sk_live_...
npx shipsite ./dist

With no API key set, it deploys a free trial site: no sign-up, 24 hours, up to 50 files and 5 MB. The URL is the only thing written to standard output, so it is easy to capture in a script.

Commands

shipsite <folder> [options]     Deploy a folder and print its URL
shipsite list                   List your sites
shipsite delete <site>          Delete a site (billing for it stops)
shipsite deploys <site>         List the versions of a site that are kept
shipsite rollback <site> [id]   Serve the previous version again, or a named one
shipsite claim <claim-token>    Move a trial site into your account
shipsite domains                List the domains you bought through shipsite
shipsite dns <domain>           List a bought domain's DNS records

Options

OptionWhat it does
--site <id>Update an existing site instead of creating a new one
--keepWith --site: leave files that are missing from the folder
--name <slug>Serve at https://<slug>.shipsite.sh
--ttl <duration>How long the site lives: seconds, or 30m, 12h, 7d. Default 24 hours
--pinKeep the site until you delete it
--password <pw>Require a password to view the site
--jsonPrint the API response as JSON

GitHub Action

In a GitHub Actions workflow, use coolsoftwaretyler/shipsite-deploy-action, which is on the GitHub Marketplace as Deploy to shipsite.sh:

- uses: coolsoftwaretyler/shipsite-deploy-action@v1
  with:
    folder: ./dist
    api-key: ${{ secrets.SHIPSITE_API_KEY }}

For CI, create a deploy-scoped API key. It can manage sites but cannot buy domains or manage keys:

curl -X POST https://api.shipsite.sh/v1/accounts/me/keys \
  -H "Authorization: Bearer sk_live_..." \
  -H "Content-Type: application/json" \
  -d '{"scope": "deploy"}'

More