-
Notifications
You must be signed in to change notification settings - Fork 9
Peeter/migrate build to gh actions #477
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Draft
ppiegaze
wants to merge
23
commits into
main
Choose a base branch
from
peeter/migrate-build-to-gh-actions
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
Conversation
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
- Remove duplicate wrangler.jsonc generation in build.yml - Add assets configuration to wrangler.jsonc for static site hosting
- Add Worker script (src/index.js) to serve static assets - Update wrangler.jsonc with proper Workers configuration - Fix both build.yml and preview.yml workflows - Use ASSETS binding for static site hosting
Deploying docs with
|
Latest commit: |
e6211c0
|
Status: | ✅ Deploy successful! |
Preview URL: | https://c7faf614.docs-dog.pages.dev |
Branch Preview URL: | https://peeter-migrate-build-to-gh-a.docs-dog.pages.dev |
- Rename wrangler.jsonc to wrangler.json for better compatibility - Add explicit entry point in deploy command - Add comprehensive debugging to troubleshoot deployment issues - Update preview workflow to use wrangler.json
- Add explicit entry point (src/index.js) to preview deploy command - Add debugging to preview workflow to show file contents - This should resolve the missing entry-point error
- Add explicit CLOUDFLARE_API_TOKEN and CLOUDFLARE_ACCOUNT_ID env vars - Wrangler requires environment variables in non-interactive mode - This should resolve the authentication error during deployment
- Change 'deploy src/index.js' to 'deploy' in both workflows - This allows wrangler to read configuration from wrangler.json - Fixes the 'need to provide a name' error in CI deployment The wrangler.json already specifies the entry point via 'main' field, so specifying it again in the command was causing it to ignore the config.
- Add --config wrangler.json to deploy command - Ensures wrangler reads the configuration file even in CI environment - Should resolve the 'need to provide a name' error
- Remove .github/workflows/build.yml - Remove .github/workflows/preview.yml - Remove wrangler.json Starting fresh to rebuild the deployment setup from scratch.
- Triggers on any push to branches except main and v1 - Automatically creates worker name from branch name - Uses existing make dist build process - Deploys to CF Workers with sanitized branch-based naming - Single job workflow for simplicity Example: branch 'feature/docs' deploys to 'feature-docs.workers.dev'
- Change deploy command to explicitly specify src/index.js entry point - Add --name flag with sanitized worker name - Add debug step to show created files before deployment - Should resolve 'Missing entry-point' error
- Add --compatibility-date 2025-08-28 to wrangler deploy command - Add --assets dist to include static files - Resolves 'compatibility_date is required' error - Now bypasses wrangler.json completely with all params in CLI
- Use single 'on: push' trigger for all branches - Job conditions handle branch filtering logic - Much cleaner than having both branches and branches-ignore
- Sanitize branch names for Cloudflare Workers preview aliases - Remove invalid characters (slashes) from alias names - Branch 'peeter/migrate-build-to-gh-actions' becomes 'pr-branch-peeter-migrate-build-to-gh-actions'
- Pre-compute branch slug in separate step with output - Use step outputs instead of inline shell command substitution - Fixes wrangler command parsing issue with shell expansion
- PR branches now deploy complete site with /docs/v2/* structure - Remove PR-scoped paths like /docs/pr-<branch>/ - PR preview URLs: https://pr-branch-\<slug\>-unionai-docs.subdomain.workers.dev/docs/v2/ - Matches production URL structure for easier testing
- Shorten preview alias to avoid length limits (pr-<slug> vs pr-branch-<slug>) - Add debugging info: branch slug, file counts, directory structure - Limit branch slug to 20 chars to avoid Cloudflare limits - Better error visibility in deployment logs
- Add '|| true' to find | head commands to prevent broken pipe errors - This was causing workflow failures when head terminated early
- Replace preview aliases with individual worker deployments - Each PR branch gets its own worker with unique name - Add debugging output for wrangler.jsonc content - This should resolve the 404 issues with preview URLs
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.
No description provided.