The accounts specified in the file do not really benefit the termux
project at the moment, so lets not link to them. Please see
https://github.com/termux/termux-packages/wiki/Donate for how to
donate to individuals until we have set up a new project account at a
suitable site.
x11-repo uses distribution x11, and root-repo distribution root.
Store this information in the json file as well, and parse it to set
both REPOSITORY_NAME and REPOSITORY_DISTRIBUTION.
Also remove unnecessary `< repo.json` from jq command, jq accepts the
file as an argument.
This fixes upload issues to x11-repo and root-repo.
Earlier in 5b8b15e7aa, I had configured
our upload scripts to treat failure of `aptly_add_to_repo` as failure to publish
packages at all. However it won't work, since even if all debs are
uploaded, and aptly_add_to_repo is called, debs are moved from temporary
directory to the repository. The proxy may drop connection during this
moment due to stale connection. And just after that we call
aptly_delete_dir which will delete the temporary directory. On the
server side, aptly will however continue to move debs from temporary
directory. Repository is published, but since the temporary directory is
removed during the transaction, the transaction never completely
succeeds. So only some of the debs are uploaded practically. This is now
fixed by adding a sleep of 180s (should be more than enough for all
stuff)
This should make automatic updates work again. docker/login-action
allows for authentication with a token instead of password.
Inspiration taken from workflow in github.com/termux/termux-docker.
This reverts commit fc95ff7881.
Unfortunately GITHUB_TOKEN authentication cannot start other action
(recent automatic update pushes haven't been built), so switch back to
a new personal access token (generated by me).
Ref: https://stackoverflow.com/a/67551255
Previously we were outputting built debs into ./debs instead of
standard folder ./output. We were also sorting built_packages.txt so
that $(cat ./built_packages.txt) returned an alphabetically sorted
list.
This caused issues for pushes that updated both a package and one or
more of its dependencies, if the dependencies start with a letter that
is later in the alphabet.
Latest example was libforestdb and libsnappy. Libforestdb depends on
libsnappy, but the buildorder as given to build-package.sh was
"libforestdb libsnappy". During the libforestdb build libsnappy was
built first, but the deb put into the standard ./output folder (that's
how our build system currently handles built dependency debs). When
build-package.sh then later tries building libsnappy it skips it
since it has already been built. We then end up with only libforestdb
in the ./debs folder.
Fix this issue by putting all debs in ./output/, and then moving the
once mentioned in built_packages.txt to ./debs/.
Fixes https://github.com/termux/termux-packages/issues/8773.
Aptly may process request for long time enough to make CloudFlare or
server drop connection. Treat this as false failure and don't stop
GitHub Actions with error status.