CI: htmldoc artifacts and package#4150
Conversation
|
And again, the CI broke because sid is broken. Might be we should make the sid package build allow to fail? I tested it: I guess it will be fixed soon in sid. |
|
I'm not sure that the webserver can use oras. Besides, I'm not sure you would want to involve yet another third party in this process. The point is that github already has stored any built artifact (like in the deb package builds). The question is whether we can exploit that. We only need the link to the artifact. |
|
And, yes, a soft-fail on Debian:sid may be appropriate. |
It is a debian package, depending how it is set up,
The only issue there is, that artifacts are linked to CI runs. So for an update you would have to download the file manually. Even wget doesn't work to download the file when you use right-click copy link due to you have to be logged in. Is this good enough? Otherwise what I found so far: |
That is a problem, right there... We can't install or sudo on the webserver.
Yes, that was what I was thinking about. Don't know if it works. That's why I was inquiring ;-) The problem was that the htmldocs run did not produce any artifacts, so we had no chance of testing in any direction.
That looks like a way. Generating a limited access token, just to get the file, may be a possibility. |
With c323d8e, the other packages are built, even if sid fails. But sid is shown red. |
I found something that works: Get url's of all artifacts that match the branch and are named linuxcnc-doc: TOKEN="YourToken"
BRANCH="ci_doc_build"
NAME="linuxcnc-doc"
curl -L \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${TOKEN}" \
-H "X-GitHub-Api-Version: 2026-03-10" \
"https://api.github.com/repos/linuxcnc/linuxcnc/actions/artifacts?per_page=100&name=${NAME}" | \
jq ".artifacts[] | select(.workflow_run.head_branch==\"${BRANCH}\") | .archive_download_url"Download the zip: curl -L \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${TOKEN}" \
-H "X-GitHub-Api-Version: 2026-03-10" \
https://api.github.com/repos/LinuxCNC/linuxcnc/actions/artifacts/7537361103/zip -o linuxcnc-doc.zipCombined: TOKEN="YourToken"
BRANCH=ci_doc_build
NAME="linuxcnc-doc"
DL_URL=$(curl -L \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${TOKEN}" \
-H "X-GitHub-Api-Version: 2026-03-10" \
"https://api.github.com/repos/linuxcnc/linuxcnc/actions/artifacts?per_page=100&name=${NAME}" | \
jq ".artifacts[] | select(.workflow_run.head_branch==\"${BRANCH}\") | .archive_download_url" | head -n1)
#DL_URL has quotes, remove them
DL_URL=${DL_URL//\"/}
curl -L \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer ${TOKEN}" \
-H "X-GitHub-Api-Version: 2026-03-10" \
"$DL_URL" -o linuxcnc-doc.zipLooks like the links are sorted by date, so I can just take the first one. Does that work for you? You need As soon as this branch is merged, you can change Edit: Using |
|
I removed the commit creating packages. |
The sid build shows still failed but other packages are built.
|
That looks very good that we might be almost there to try. @andypugh This might be able to restore the devel docs on the webserver. Can you check on the webserver if it has |
|
There will shure be a way. Otherwhise just copy over the binary of jq or cobble together something in bash / awk to get the right url string. |
|
This also bites |
Sorry, I missed this last night, and don't have the relevant keys on my work laptop. I can check when I get home. |


This PR adds:
A published package for htmldocsRemovedoras pull ghcr.io/linuxcnc/linuxcnc/doc-html:masterIf needed for the 2.9 branch, I can backport this.
The discussion started in: #4119
As much as I understand the github docs, only members are allowed to write packages. So PR's should not be able to create a package, even if one removes theif()to only run this stage always.For testing, I run this stage in my github account: https://github.com/hdiethelm/linuxcnc-fork/actions/runs/27276506335The package is here: https://github.com/hdiethelm/linuxcnc-fork
And can be downloaded with:
oras pull ghcr.io/hdiethelm/linuxcnc/doc-html:ci_doc_build_test@BsAtHome
Do you thing this does the job?
I will create a commit that removes the if() and see what happens. Then I will revert it again.