5 minutes
Understand How Publishing Works
Four familiar tools now become one connected route from your computer to the Internet.
Commit
Save a clear version of your project on your computer.
Push
Send those saved changes to your GitHub repository.
Deploy
Build and publish the website so anyone can visit it.
Checkpoint
10–15 minutes
Prepare for Cloudflare Workers
Keep your design exactly as it is while Codex prepares the technical bridge between Astro and Cloudflare.
- 01
Open the existing project
In Codex, select zia-portfolio—the same project you used in Lesson 04.
- 02
Prepare Astro
Your portfolio is a static website. Astro creates the finished files before Cloudflare publishes them; you do not need a complicated server.
“Prepare my static Astro website for Cloudflare Workers, including the required configuration files. Keep my design unchanged and check that the build works.”
Deployment settings
npm run buildPrepares the finished website.
distContains the website files.
Use the command confirmed for your project.
You don’t need to memorise these settings or edit technical configuration files yourself.
“Check that my project is safe to publish. Make sure no passwords, private files, or unnecessary large photographs are included.”
Checkpoint
5 minutes
Send Your Website to GitHub
Your first push sends the local save points from GitHub Desktop to your private online repository.
- 01
Open GitHub Desktop
Select zia-portfolio and make sure the current branch is main.
- 02
Push your project
Click Push origin and wait until the transfer is complete.
- 03
Check GitHub
Open your repository online. You should see folders and files such as
src,public, andpackage.json.
Checkpoint
15–25 minutes
Publish With Cloudflare Workers
Connect the repository once, confirm the settings, and let Cloudflare build the first public version.
Open the Cloudflare dashboard ↗- 01
Open Workers & Pages
Choose Create application, then look for the option to import a GitHub repository using the Workers deployment flow.
- 02
Connect GitHub
Authorize access to zia-portfolio. When possible, give Cloudflare access only to this repository.
- 03
Name the Worker
Use a simple name such as zia-portfolio. If unavailable, choose a clear variation.
- 04
Confirm the configuration
Use
npm run build,dist, and the deploy command Codex confirmed for your project. - 05
Start the deployment
Wait for both the Astro build and the Cloudflare deployment to succeed.
If the deployment fails
“My Cloudflare deployment failed. Here’s the error message. Can you help me fix it?”
Checkpoint
5–10 minutes
Visit & Test Your Live Website
Cloudflare gives you a public address—usually ending in workers.dev. Open it and test the real experience.
Review the homepage
- Photographs load
- Text is readable
- Navigation works
- Nothing is broken
Check the mobile view
- Photos fit the screen
- Text stays comfortable
- The menu opens
- Nothing is cut off
Checkpoint
10–15 minutes
Publish Your First Update
Prove that the connection works by sending one small, visible change all the way to the live website.
“Make the introduction on my homepage shorter.”
- 01
Make and preview the change
Open zia-portfolio in Codex, request a small edit, and check the result in your local preview.
- 02
Commit and push
In GitHub Desktop, use a clear summary such as
Update homepage introduction, commit to main, then click Push origin. - 03
Watch Cloudflare
A new deployment should start automatically. You should not need to click Deploy again.
- 04
Verify the live update
Refresh the public website and confirm that your change is visible.