treosh / lighthouse-ci-action

Audit URLs using Lighthouse and test performance with Lighthouse CI.
MIT License
1.18k stars 83 forks source link

Add uploadExtraArgs support #107

Closed Djiit closed 9 months ago

Djiit commented 2 years ago

Hi there :wave:,

Trying to add support for extraArgs for the upload command, mostly to be able to pass extraHeaders (but can be arbitrary args).

Any guidance are appreciated, I might have missed something.

I'm also OK to refactor this and focus on uploadExtraHeaders (a less generic version) if it makes more sense.

Cheers

Fixes #94

Djiit commented 2 years ago

Hey @alekseykulikov , any chance to have this reviewed or merged anytime soon ? Thanks 🙏

alekseykulikov commented 2 years ago

Hi @Djiit ! Could you clarify your case, why do you need custom http headers? The action supports serverBaseUrl & serverToken to upload to LHCI Server.

Djiit commented 2 years ago

Hey, thanks for your answer. In my case, my server sits behind cloudflare and I need to pass an arbitrary header to reach it.

Djiit commented 2 years ago

@alekseykulikov any news? Thanks 🙏

Djiit commented 2 years ago

Hey @alekseykulikov do you think we can merge this ?

alekseykulikov commented 2 years ago

Hey, we could, but I'm unsure about the balance of extra complexity vs. usefulness. Let's keep the issue open and see if more people need it.

diimpp commented 1 year ago

+1 for the feature.

I would like to execute upload with --githubStatusContextSuffix to be able to different between multiple runs (mobile, desktop) for the same url

      await exec.exec('lhci', ['upload', '--githubStatusContextSuffix', '/mobile']);

https://github.com/GoogleChrome/lighthouse-ci/issues/138#issuecomment-1196379684

tanguyantoine commented 1 year ago

It would be very helpfull