neoascetic / rawgithack

Serves files from github, bitbucket and gitlab, but with the correct content types
https://raw.githack.com
MIT License
577 stars 89 forks source link

Support Gitlab CI artifacts #42

Closed kasbah closed 3 years ago

kasbah commented 5 years ago

As discussed in #39 and #40 Gitlab CI artifacts currently, kind of work, so much that I assumed they were supported. But:

  1. Using git ref urls that re-direct to specific job artifacts ends up re-directing to gitlab.com. This is a more general issue and tracked as #41

https://glcdn.githack.com/openflexure/openflexure-microscope/-/jobs/artifacts/master/raw/builds/main_body_LS65.stl?job=STLs

re-directs to

https://gitlab.com/openflexure/openflexure-microscope/-/jobs/223115318/artifacts/raw/builds/main_body_LS65.stl

so when I try and use URLs like that that grab the latest artifacts from the master branch I get CORS errors.

  1. Query parameters are not supported by the cache and the frontend utility that tells you what the URLs are but:

https://gl.githack.com/openflexure/openflexure-microscope/-/jobs/artifacts/master/raw/builds/main_body_LS65.stl serves a 404 and https://gl.githack.com/openflexure/openflexure-microscope/-/jobs/artifacts/master/raw/builds/main_body_LS65.stl?job=STLs serves the file :/

This could maybe be a more general issue around supporting query parameters?

Are there any other potential issues with supporting Gitlab CI artifacts that haven't been mentioned yet?

neoascetic commented 3 years ago

Hey. Just curious. Looks like gitlab has changed its URL format for job artefacts and it is possible to link them now?

kasbah commented 3 years ago

Looks like it works now, yeah.