You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
gh-36970: CI: Upload test stats as artifacts, improve output of "List Docker images"
<!-- ^^^^^
Please provide a concise, informative and self-explanatory title.
Don't put issue numbers in there, do this in the PR body below.
For example, instead of "Fixes#1234" use "Introduce new method to
calculate 1+1"
-->
<!-- Describe your changes here in detail -->
- `tox -e docker-....` now copies logs and stats from the image to the
tox environment directory
- CI Linux and CI Linux Incremental (via docker.yml) prepare the logs
artifact from there (they used to be in charge of copying the logs from
the image)
- We switch from the legacy Docker builder to the current one
("buildkit"), avoiding deprecation warnings (e.g. https://github.com/sag
emath/sage/actions/runs/7342841283/job/19992633064?pr=36977#step:11:29)
- We also improve the output of the step "List Docker images":
- It no longer advertises Docker images if they could not be pushed
to the registry - see https://github.com/sagemath/sage/actions/runs/7335
489109/job/19973517180?pr=36970#step:15:60
- When it is able to push, it now shows instructions for developers
what to do with them - see https://github.com/mkoeppe/sage/actions/runs
/7345058426/job/19997709977#step:15:61 - and also creates an Annotation
- see https://github.com/mkoeppe/sage/actions/runs/7345058426
- Just to trigger the CI Linux Incremental workflow here on the PR, we
include the upgrade of the `info` package.
In a follow-up:
- We could store the stats in a persistent database
<!-- Why is this change required? What problem does it solve? -->
<!-- If this PR resolves an open issue, please link to it here. For
example "Fixes#12345". -->
<!-- If your change requires a documentation PR, please link it
appropriately. -->
### 📝 Checklist
<!-- Put an `x` in all the boxes that apply. -->
<!-- If your change requires a documentation PR, please link it
appropriately -->
<!-- If you're unsure about any of these, don't hesitate to ask. We're
here to help! -->
<!-- Feel free to remove irrelevant items. -->
- [x] The title is concise, informative, and self-explanatory.
- [x] The description explains in detail what this PR is about.
- [ ] I have linked a relevant issue or discussion.
- [ ] I have created tests covering the changes.
- [ ] I have updated the documentation accordingly.
### ⌛ Dependencies
<!-- List all open PRs that this PR logically depends on
- #12345: short description why this is a dependency
- #34567: ...
-->
<!-- If you're unsure about any of these, don't hesitate to ask. We're
here to help! -->
URL: #36970
Reported by: Matthias Köppe
Reviewer(s): Kwankyu Lee, Matthias Köppe
if [ -f .tox/$TOX_ENV/Dockertags ]; then CONTAINERS=$(docker create $(tail -1 .tox/$TOX_ENV/Dockertags) /bin/bash || true); fi
253
-
if [ -n "$CONTAINERS" ]; then for CONTAINER in $CONTAINERS; do for ARTIFACT in /sage/logs; do docker cp $CONTAINER:$ARTIFACT artifacts/$LOGS_ARTIFACT_NAME && HAVE_LOG=1; done; if [ -n "$HAVE_LOG" ]; then break; fi; done; fi
elif [ -n "$DOCKER_PUSH_REPOSITORY" -a -f .tox/$TOX_ENV/Dockertags ]; then
297
+
echo "Unable to push Docker images to $DOCKER_PUSH_REPOSITORY."
298
+
echo "This is normal in a pull request to sagemath/sage or to another user's repository."
299
+
echo
300
+
echo "If you need Docker images, "
301
+
echo " - either run this GitHub Actions workflow in your repository fork"
302
+
echo " - or use the method described in https://doc.sagemath.org/html/en/developer/portability_testing.html#automatic-docker-based-build-testing-using-tox"
0 commit comments