Skip to content
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

docs: update guides/deploy/cloudflare.mdx #10790

Merged
merged 4 commits into from
Feb 5, 2025

Conversation

vrabe
Copy link
Contributor

@vrabe vrabe commented Jan 24, 2025

Description (required)

The steps to deploy with git are still strange.

  1. All these steps are to set up a new project on Cloudflare Pages. Step 1 seems redundant.
  2. It seems that selecting an account isn't done in "Workers" page. I can't verify that because I don't have multiple accounts.
  3. We don't have to explicitly select "Overview". It shows up after clicking "Workers & Pages".
  4. "Create application" button seems to be renamed to "Create":

cloudflare

Related issues & labels (optional)

  • Closes #
  • Suggested label: improve or update documentation

Copy link

netlify bot commented Jan 24, 2025

Deploy Preview for astro-docs-2 ready!

Built without sensitive environment variables

Name Link
🔨 Latest commit 64fbb8d
🔍 Latest deploy log https://app.netlify.com/sites/astro-docs-2/deploys/67a345990f7754000826ce20
😎 Deploy Preview https://deploy-preview-10790--astro-docs-2.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@astrobot-houston
Copy link
Contributor

astrobot-houston commented Jan 24, 2025

Lunaria Status Overview

🌕 This pull request will trigger status changes.

Learn more

By default, every PR changing files present in the Lunaria configuration's files property will be considered and trigger status changes accordingly.

You can change this by adding one of the keywords present in the ignoreKeywords property in your Lunaria configuration file in the PR's title (ignoring all files) or by including a tracker directive in the merged commit's description.

Tracked Files

File Note
en/guides/deploy/cloudflare.mdx Source changed, localizations will be marked as outdated.
Warnings reference
Icon Description
🔄️ The source for this localization has been updated since the creation of this pull request, make sure all changes in the source have been applied.

@sarah11918
Copy link
Member

Thank you for contributing this! I will ask for feedback from others who use Cloudflare to confirm the steps! Perhaps @alexanderniebuhr is able to verify here?

@sarah11918 sarah11918 added the improve or update documentation Enhance / update existing documentation (e.g. add example, improve description, update for changes) label Jan 29, 2025
@alexanderniebuhr
Copy link
Member

I think for users with multiple accounts this is different. I'll check tomorrow my time :)

@hkbertoson
Copy link
Contributor

Just checked it on my Cloudflare Account with Multiple accounts and it looks just fine to me.


3. Log in to the Cloudflare dashboard and select your account in **Account Home** > **Compute (Workers)** > **Workers & Pages** > **Overview**.
3. Go to **Account Home** > **Compute (Workers)** > **Workers & Pages**.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think you need to go to the Account Home menu, let me know if you have any other thoughts.

Suggested change
3. Go to **Account Home** > **Compute (Workers)** > **Workers & Pages**.
3. Go to **Compute (Workers)** > **Workers & Pages**.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jsparkdev You're right.

In Cloudflare Docs:

Pages offers support for GitHub and GitLab. To create your first Pages project:

  1. Log in to the Cloudflare dashboard and select your account.
  2. In Account Home, select Workers & Pages.
  3. Select Create application > Pages > Connect to Git.

It seems that after login/selecting an account, you are in Account Home. Do we need to point out this?

Suggested change
3. Go to **Account Home** > **Compute (Workers)** > **Workers & Pages**.
3. In Account Home, select **Compute (Workers)** > **Workers & Pages**.

Or just apply your change?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vrabe

It seems right to describe it in the official documentation :)

@alexanderniebuhr
Copy link
Member

Yeah as I said, for multi accounts you need to select the account after login, but I think that is already described. However I just attached the Cloudflare Dashboard flow as a screencast, for others to compare with the written steps, hope that helps:

Screen.Recording.2025-01-30.at.06.54.29.mov

@sarah11918
Copy link
Member

Thanks for jumping in everyone!!

I will note, this is why we try to describe other services, dashboards etc. as generally as possible because we can't control (and often don't know) when these update. As evidenced by the maintenance burden this is causing now. 😅

I would be fine with a PR suggestion that describes what you need to do accurately, but I would prefer as much of a generic, future proof solution as possible.

e.g. If you have to set something on "Workers and Pages", then it's not our job to say exactly how to get there. Their own docs should explain where Workers and Pages is in their UI and how to get there. In fact, if there's no guarantee that that setting will always even be found at "Workers and Pages", it is most future proof to just specify the setting that needs configuring, and someone can find that setting through Cloudflare's own documentation about setting that value. The frequency with which a setting, action, or option name changes is much lower than the frequency with which the dashboard or UI could get updated or rearranged.

So with that in mind, I'll ask you to give a fresh look over these instructions and see what, if anything, can be generalized for future-proof instructions! It's not our job to teach Cloudflare's current dashboard/UI -- only to let Cloudflare users know what must be configured to work with an Astro project!

@vrabe
Copy link
Contributor Author

vrabe commented Feb 3, 2025

If we want it general, maybe we need to change it back to the original style. Something like:

<Steps>
1. Push your code to your git repository (GitHub, GitLab).

2. Set up a new project on Cloudflare Pages. Use the following build settings:

    - **Framework preset**: `Astro`
    - **Build command:** `npm run build`
    - **Build output directory:** `dist`

3. Click the **Save and Deploy** button.
</Steps>

@sarah11918
Copy link
Member

That honestly looks amazing to me! Does that satisfy the original need for updating this page?

@vrabe
Copy link
Contributor Author

vrabe commented Feb 4, 2025

I don't mind changing to that.

Copy link
Member

@sarah11918 sarah11918 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SHIP. IT. 🥳

@sarah11918 sarah11918 added the Merge Queue Approved and ready to be merged (wait for feature release if also labelled M-O-R)! label Feb 4, 2025
@ArmandPhilippot ArmandPhilippot merged commit 447153c into withastro:main Feb 5, 2025
10 checks passed
ArmandPhilippot added a commit to ArmandPhilippot/astro-docs that referenced this pull request Feb 5, 2025
thomasbnt pushed a commit that referenced this pull request Feb 5, 2025
@vrabe vrabe deleted the update-cloudflare branch February 6, 2025 09:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
improve or update documentation Enhance / update existing documentation (e.g. add example, improve description, update for changes) Merge Queue Approved and ready to be merged (wait for feature release if also labelled M-O-R)!
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants