Skip to content

Fix/pr previews#2

Merged
cau1k merged 2 commits intomainfrom
fix/pr-previews
Dec 4, 2025
Merged

Fix/pr previews#2
cau1k merged 2 commits intomainfrom
fix/pr-previews

Conversation

@cau1k
Copy link
Copy Markdown
Member

@cau1k cau1k commented Dec 4, 2025

Summary by CodeRabbit

  • New Features

    • GitHub Actions workflows now automatically post preview deployment URLs as pull request comments for easier preview access.
  • Chores

    • Added environment variable configuration for stage-based deployments (development and production).
    • Integrated Cloudflare credentials into deployment workflows.
    • Updated domain routing to support environment-specific URLs.

✏️ Tip: You can customize this high-level summary in your review settings.

@cau1k cau1k merged commit 36e94a1 into main Dec 4, 2025
2 of 3 checks passed
@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Dec 4, 2025

Caution

Review failed

The pull request is closed.

Walkthrough

GitHub Actions workflows are updated to support Cloudflare deployments by adding CLOUDFLARE_ZONE_ID environment variables to preview and production jobs. A new step creates or updates PR comments with preview deployment URLs. The Alchemy configuration now dynamically sets domains and stage values based on the STAGE environment variable.

Changes

Cohort / File(s) Summary
GitHub Actions Workflows
.github/workflows/docs-pr-preview.yml, .github/workflows/docs-publish.yml
Added CLOUDFLARE_ZONE_ID environment variable to workflow jobs (preview and production). New "Comment Preview URL" step in preview workflow computes preview URL, formats Markdown message, and creates or updates PR comment with deployment link.
Alchemy Configuration
apps/docs/alchemy.run.ts
Introduced stage and isProd constants derived from STAGE environment variable. Replaced static stage assignment with dynamic constant. Updated website domains for Nextjs app to support environment-specific subdomains (e.g., ${stage}.better-slop.com for non-production).

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

  • Verify the preview URL computation logic and Markdown message formatting in the PR comment script
  • Ensure the stage/isProd constants correctly interpret the STAGE environment variable
  • Confirm that domain switching logic properly handles production vs. non-production environments

Poem

🐰 The workflows now bloom with Cloudflare's might,
Preview URLs dance in comments so bright,
Stages and domains, configured just right,
No more hardcoded strings—flexibility in flight! ✨

✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch fix/pr-previews

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 6fd1977 and 19e79d7.

📒 Files selected for processing (3)
  • .github/workflows/docs-pr-preview.yml (2 hunks)
  • .github/workflows/docs-publish.yml (1 hunks)
  • apps/docs/alchemy.run.ts (1 hunks)

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@cau1k cau1k deleted the fix/pr-previews branch December 4, 2025 21:55
@github-actions
Copy link
Copy Markdown

github-actions bot commented Dec 4, 2025

Preview Deployment

🔗 https://pr-2.better-slop.com

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant