2026-07-27: PR Preview environments

Every pull request can now be deployed automatically to a short-lived, browser-accessible instance, so reviewers can click through a change instead of building it locally. Key features:

  • Deployed when a PR opens, updated on every push, torn down on merge/close (with a TTL as a safety net).
  • A bot comment posts the link at https://<owner>-<repo>-pr-<number>-<hash>.preview.codefloe.com.
  • Works with both Crow CI and Forgejo Actions, for static sites and containers.

Example pipeline/workflow definitions for both CI systems can be found at codefloe/roost-preview-examples.

Official docs: Preview Environments | CodeFloe

4 Likes

Amazing work, thank you!

1 Like

This is really cool,

Question though, when deploying docker images / ssr would it be possible build and deploy the image in the same container without uploading to packages?

Since there is a quota for packages and images built for preview aren’t necessary to keep around anyways?

Not as of today with the current architecture but we can check what is possible. Agreed that saving up & download + cleanup would be a cool improvement!

1 Like

Found a few issues:

  1. https://codefloe.com/codefloe/roost-preview-examples/src/branch/main/README.md references https://docs.codefloe.com/usage/pr-previews/ which 404
    1. correct link should be Preview Environments | CodeFloe
  2. For using Forgejo actions do we need to manually set ROOST_SERVER?
    1. I didn’t see any documentation for the codefloe roost url
    2. running deploy results in an error for me
    3. preview-deploy
      error: Post "http://127.0.0.1:7420/v1/previews": dial tcp 127.0.0.1:7420: connect: connection refused
      ⚙️ [runner]: exitcode '1': failure
      
  1. Thanks.
  2. We forgot to set it globally - now done. You shouldn’t need to set it for yourself but just retrieve the global variable: ${{ vars.ROOST_SERVER }}. We’ve also updated the examples with this new setting.
1 Like