cloudflare / pages-action

MIT License
468 stars 95 forks source link

Output branch URL #73

Closed jasonkuhrt closed 1 year ago

jasonkuhrt commented 1 year ago

So that we can put a link in PR comments for a deployment URL for that branch like CF Pages GH app does (e.g. see CF Pages app output vs our custom one):

CleanShot 2023-03-20 at 15 50 29@2x
WalshyDev commented 1 year ago

This is already provided in the alias output.

jasonkuhrt commented 1 year ago

Hm, it does not behave how I expected. Is this a bug or expected? How can the GH action output a URL as does the CF GH App? That's what this issue was about.

CleanShot 2023-03-20 at 17 14 32@2x
WalshyDev commented 1 year ago

There's a case where it doesn't have the actual alias like half the time. That's an issue with the Pages API however not this action.

(reason for this is wrangler will exit before the edge deployment however we only update the pointed alias after the edge deploy. So, if the edge deploy hasn't been completed by the time we do our API request, the alias hasn't been updated.)

jasonkuhrt commented 1 year ago

@WalshyDev interesting, is this expected to improve or not really? At least now I have a good link to put in our code comment, thanks!

WalshyDev commented 1 year ago

We'll fix the issue at some point but it isn't a high priority so it'll be fixed when someone has some free time and wants to fix it.