Commit Graph
104 Commits
Author SHA1 Message Date
Pablo Correa Gómez cd404bd5f9 ci: remove split of static CI jobs into more places
Since the previous commits, there is only one job making use of
.package-test hidden job, so merge it into the main file, as the
include just makes the whole thing harder to follow.

Signed-off-by: Pablo Correa Gómez <pabloyoyoista@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/9349>
2026-08-23 12:47:35 +00:00
Pablo Correa Gómez 2b9d12adfa ci: remove the testlib and gitlab-ci boilerplate associated with it
We no longer need it, since things running CI directly in pmaports are
now using the packaged version of testlib and abuild check

Signed-off-by: Pablo Correa Gómez <pabloyoyoista@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/9349>
2026-08-23 12:47:35 +00:00
Aelin b7260883a6 ci: Run kconfig generate in CI on kconfigcheck changes
kconfigcheck changes can be validated with the generic kernels and we
don't want changes to kconfigcheck to break generic kernel config
generation.

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/9344>
2026-08-08 15:37:12 +00:00
Clayton Craft b0953c42d9 ci: add generic kernel check
This runs 'kconfig generate' for all archs that the generic kernels
support in order to make sure that kconfig-generic.toml changes are
valid for everything for the kernels it would apply to. This is meant
to catch kconfig changes that might introduce options that don't exist
on some kernel/arch combos or that might be missing other kconfig
dependencies.

Signed-off-by: Clayton Craft <craftyguy@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/9250>
2026-08-05 13:20:24 +00:00
Aster Boese cd3a15a480 gitlab-ci: check kconfig when APKBUILD of kernel package is modified
Previously, kconfigcheck would only run if the kernel configs of a
kernel package where changed. This means that, if a kernel package
is not directly upgraded, the kernel config will most likely never
be touched, leading to extremely out-of-date kernel configs.
Checking when the APKBUILD is modified instead would force the
check at every modification of a kernel package, forcing more
up-to-date configs.

Signed-off-by: Aster Boese <asterboese@mailbox.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/8923>
2026-06-28 07:55:51 +00:00
Oliver Smith 75b8400f82 CI: aport-lint: use alpine:edge
I was wondering why apkbuild-lint found a bug locally but not in CI:

IC[AL65]:main/postmarketos-ui-phosh/APKBUILD:66:2:non-local 'install' variable in function 'openrc'. Add install scripts to global install variable instead.

The reason is that the we use alpine:latest here. Let's change it to
alpine:edge so we have the most recent abuild-go version that finds the
most APKBUILD linting bugs.

Signed-off-by: Oliver Smith <ollieparanoid@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/8735>
2026-06-07 10:09:14 +00:00
Stefan Hansson 2dec667f00 CI: Add check for required pmbootstrap version's age
While ideally everyone would be running the latest pmbootstrap version,
in practice people don't always update right away. And even if they want
to, their distribution may not have the latest version packaged yet.
Let's enforce some wiggle room here so distributions have time to catch
up before we require newer versions.

Signed-off-by: Stefan Hansson <newbyte@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/8550>
2026-05-13 21:16:39 +00:00
Luca Weiss 1ab8eefdd5 CI: Run dint job on all files on deviceinfo_schema.toml change
Similar to kconfigcheck.toml, let's run the dint job on all deviceinfo
files when the spec itself is changed. This allows to catch possible new
warnings and errors early and fix them.

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/8139>
2026-03-20 01:57:32 +00:00
Stefan Hansson cfff222fb2 CI: Add mypy check
Signed-off-by: Stefan Hansson <newbyte@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7960>
2026-03-12 18:53:15 +00:00
Stefan Hansson 8145270334 CI: build docs on changes to build-docs.sh script
Otherwise we may end up with errors that aren't noticed until something
else triggers this.

Signed-off-by: Stefan Hansson <newbyte@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7983>
2026-02-10 10:16:54 +01:00
Stefan Hansson b9db67e42d CI: build and deploy docs on deviceinfo schema change
The deviceinfo schema is used to generate the "Deviceinfo Reference"
page, so we should consider changes to it as part of changes to the
documentation.

Signed-off-by: Stefan Hansson <newbyte@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7983>
2026-02-10 10:16:52 +01:00
Pablo Correa Gómez e01c66bb46 ci: set PYTHONPATH for the pmb module globally
Signed-off-by: Pablo Correa Gómez <pabloyoyoista@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7868>
2026-02-01 21:06:14 +00:00
Pablo Correa Gómez 32e058f2ea ci: rename commits ci script to check-changed-versions
So it actually explains what it does. In the process, make the name of
the Python file it executes also consistent.

Signed-off-by: Pablo Correa Gómez <pabloyoyoista@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7868>
2026-02-01 21:06:14 +00:00
Pablo Correa Gómez af81f21fba ci: simplify local usage of generate_build_jobs
There's no need why we can't have a default value

Signed-off-by: Pablo Correa Gómez <pabloyoyoista@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7725>
2026-01-24 22:09:38 +00:00
Pablo Correa Gómez 11e8136f44 ci: fetch ci-common files from "main" branch
Relates https://gitlab.postmarketos.org/postmarketOS/postmarketos/-/issues/122

Signed-off-by: Pablo Correa Gómez <pabloyoyoista@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7726>
2026-01-14 16:48:52 +00:00
Casey Connolly eaf6ff6567 CI: don't deploy docs from scheduled pipelines
The package auto-update runs in a scheduled pipeline, it should be
the only job that runs however a discrepency in the rules for the
deploy-docs job results in it running as well.

To mitigate this, add an additional rule to never run the job in a
scheduled pipeline.

Signed-off-by: Casey Connolly <kcxt@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7457>
2025-11-30 16:47:54 +01:00
Jens Reidel a9be71b496 ci: Build docs with Sphinx
Signed-off-by: Jens Reidel <adrian@postmarketos.org>
Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7295>
2025-11-05 11:21:33 +00:00
Stefan Hansson 6e75e62302 CI: dint: don't mark job as failed if only warnings were raised
In the case of there being warnings but no errors, dint will set its
exit code to 2. We don't want the pipeline to fail in this case, so have
2 be an allowed failure exit code.

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7083>
2025-10-01 12:03:26 +00:00
Pablo Correa Gómez c42e5e9a32 ci: make the pipeline trigger on the default branch
So that we can deploy docs. In the process, replace "master" with
CI_DEFAULT_BRANCH, so it does not break when we rename.

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7077>
2025-09-25 19:55:33 +00:00
Pablo Correa Gómez ce47303e35 ci: add job to build docs and trigger handbook pipeline for deployment
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7065

[ci:skip-build]: already built successfully in CI
2025-09-24 12:37:31 +02:00
Stefan Hansson aa74915a68 CI: Add deviceinfo linting via dint
Needs https://gitlab.postmarketos.org/postmarketOS/pmbootstrap/-/merge_requests/2679
to run locally.

Tested and works locally with 'pmbootstrap ci' as well as in GitLab CI.

Closes https://gitlab.postmarketos.org/postmarketOS/pmaports/-/issues/2583

Part-of: <https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/7006>
2025-09-20 09:30:46 +00:00
Martin Roukala (né Peres) a0fd5e421c ci: add support for building and testing device boot images
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6696
2025-07-30 12:54:24 +02:00
Pablo Correa Gómez 6622982587 ci: remove global before_script
We should not need to apk upgrade on stable just to check that MR
settings are correct. Simplify that, and remove an anchor only used in
one place.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6471
[ci:skip-build]: already built successfully in CI
2025-05-13 09:37:57 -07:00
Pablo Correa Gómez fe2009a846 ci: avoid using alpine:edge on lint CI jobs
It is a lot more prone to breaking than stable, which is the
default. The reason to have them there is also not very clear.
The editor-config has been there since its introduction in
e7a8141113. It might be that at the time
it was not in community or in a stable release. The shellcheck-grep
has been there since 81872a59c1, which
was already 6 years ago. Probably at the time our tooling was a lot
less integrated and stable in alpine as it is today, and everything
was running edge.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6471
2025-05-13 09:37:57 -07:00
Pablo Correa Gómez 437edbcce9 ci: simplify rules for running pipelines
We were formerly running pipelines on branches when we directly pushed
or cherry-picked commits. That is no longer the case, and this is just
leftover from that.

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6471
2025-05-13 09:37:57 -07:00
Pablo Correa Gómez 967b9e5756 ci: add build-jobs.yaml.j2 to all changes that have gitlab-ci.yml
When one applies, the other one does too

Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6399
[ci:skip-build]: already built successfully in CI
2025-05-13 09:34:45 -07:00
Pablo Correa GómezandClayton Craft 218d0b1745 ci: build packages in a child pipeline instead of in the main one (MR 6366)
Following Alpine's example. This allows some optimizations:
* Don't start one job per architecture simply to skip them after
  rebase and before merge
* If there are no packages, don't start the jobs at all (not true,
  gitlab bug)
* Avoid creating jobs for architectures that don't have changed
  packages, thus further reducing the unnecessary
  jobs and possibly reducing transient failures

Co-authored-by: Clayton Craft <clayton@craftyguy.net>
2025-04-11 12:26:20 -07:00
Pablo Correa Gómez 65038ce26a ci: split verifying package checksums into its own job (MR 6366)
This simplifies the build_changed_aports job, and makes it a lot
easier to use dynamic pipelines in the future
2025-04-11 12:02:24 -07:00
Caleb Connolly 1e7fe0c4f7 CI: introduce shell unit-test infra
Introduce some basic infrastructure to allow running per-package unit
test jobs, as well as a library to support unit-testing shell scripts.

Packages can provide their own unit tests by adding a tests/
subdirectory to the package, this should contain a .gitlab-ci.yml file
with jobs that extend the .package-test job template as well as any
supporting data and scripts.

Signed-off-by: Caleb Connolly <caleb@postmarketos.org>
Part-of: https://gitlab.postmarketos.org/postmarketOS/pmaports/-/merge_requests/6182
2025-04-08 13:35:31 -07:00
Pablo Correa Gómez eb18caefb5 Update APKBUILDS to use Maintainer and Co-Maintainer instead of CODEOWNERS (MR 6272)
We now have a bot that reads those lines from APKBUILD files, instead
of using a proprietary gitlab feature. Relevant changes:

* Change @ollieparanoid for @Newbyte as maintainer for GNOME packages
  where Oliver was listed.
* Don't add @craftyguy as Librem5 maintainer, as he dropped it long
  ago
* Remove entries referencing archived ports
* Don't touch jenneron's maintainership. That's a task for another day
* Don't add "balejk" as maintainer. We have tried pinging them, but
  seem to be currently idle
  person is. Help figuring it out would be welcomed.
* Don't add "binarycraft" as maintainer. Last contribution was years
  ago: https://gitlab.com/binarycraft
* Don't add more maintainers to linux-postmarketos-qcom-msm8953, as it
  would have ended up with 7, which might be a bit too much
* Don't add more maintainers to the PinePhone. The current ones seem
  to actually be the most active
* Don't add Danct12 to N900. Sicelo has been single-handedly managing
  it for a long while
* Update maintainer emails for Nikita Travkin, Alexey Minnekhanov, and
  Barnabás Czémán

[ci:skip-vercheck] Co-Maintainer changes require no pkgrel updates
since the names do not make it to the package itself

[ci:ignore-count]

Fixes #3530
[ci:skip-build]: already built successfully in CI
2025-03-04 12:50:09 +01:00
Caleb Connolly 448d56e4cb CI: use QEMU-friendly runner where necessary (MR 6143)
The OSUOSL provided runners have issues with QEMU, switch to our own.

[ci:skip-vercheck]
[ci:skip-build]: already built successfully in CI
2025-02-05 23:18:54 +01:00
Clayton Craft 5f4f465db0 Revert "CI: use resource groups for qemu build test jobs (MR 6132)"
This reverts commit 0eaba406fe.
Resource groups dramatically reduced CI throughput for these jobs,
blocking pipelines for a really really long time.
2025-02-04 01:17:53 -08:00
Clayton Craft 84b19f67f3 CI: use aarch64 gitlab runners for aarch64 build testing (MR 6140)
We have it so let's use it.
2025-02-03 15:03:21 -08:00
Clayton Craft 0eaba406fe CI: use resource groups for qemu build test jobs (MR 6132)
This uses resource groups in gitlab CI to limit the cross arch build
test jobs to only allow one at a time.

This is a workaround for
https://gitlab.postmarketos.org/postmarketOS/postmarketos/-/issues/83

[ci:skip-build]: already built successfully in CI
2025-02-03 00:44:06 -08:00
Caleb Connolly 6ca9e65fb3 CI: kconfig: allow failure when updating kconfigcheck.toml (MR 5836)
When enabling new options in kconfigcheck, it's likely that some kernels
in pmaports will fail, but often undesirable to rebuild all the kernels
particularly when the options being enabled are for quality of life.

Adjust the rules for the kconfig check job in CI so that it will fail
with a warning in this case, but still fail with an error when an
updated kernel package doesn't pass.

Signed-off-by: Caleb Connolly <caleb@postmarketos.org>
[ci:skip-build]: already built successfully in CI
2025-01-06 16:39:46 -08:00
Caleb Connolly 85503434af CI: use yaml anchors for common job rule (MR 5836)
Signed-off-by: Caleb Connolly <caleb@postmarketos.org>
2025-01-06 16:39:46 -08:00
Stefan Hansson e1be115971 CI: Don't bother with main/linux-*/config-* in kconfig check (MR 5838)
We haven't had kernels in main/ for soon three years[1], so no need
to bother checking this location.

 [1]: See commits 47d8f823..8f24fe3a
[ci:skip-build]: already built successfully in CI
2024-11-22 22:49:25 -08:00
Clayton Craft 344658db76 CI: gitlab: increase git clone depth to 100 (MR 5718)
Technically this option can be configured in the Gitlab UI, but I spent
about 3 hours debugging a CI failure caused by it being too low and
I don't want to risk forgetting this can happen later if/when someone
decides to lower it in the UI. By setting it here, we can have some
context/history about why.

This fixes the CI in !5688

Also see:
https://docs.gitlab.com/17.4/ee/user/project/repository/monorepos/index.html#shallow-cloning
[ci:skip-build]: already built successfully in CI
2024-10-19 14:07:38 +02:00
Pablo Correa Gómez 8e1d778ecc ci: fix paths to point to gitlab.postmarketos.org (MR 5696) 2024-10-07 12:57:38 +02:00
Stefan Hansson 9fbd64fce0 Revert "ci: switch to pmbootstrap v3 (MR 5566)" (MR 5658)
As of
https://gitlab.com/postmarketOS/ci-common/-/commit/666df6d1333ee1699d13bf6f75ab0f66b78aaa42
the default pmbootstrap version used is master, not 2.3.x. As such,
let's avoid duplicating that downstream.

Closes https://gitlab.com/postmarketOS/pmbootstrap/-/issues/2396

This reverts commit 7a930582d7.
2024-09-29 16:33:03 +02:00
Clayton Craft 7a930582d7 ci: switch to pmbootstrap v3 (MR 5566) 2024-09-09 12:07:25 -07:00
Clayton Craft cccdf68e82 ci: stop using the "big" Gitlab CI runners (MR 5565)
These runners seem to no longer be available to contributors who submit MRs from their personal forks.

I reported this to Gitlab here: https://gitlab.com/gitlab-org/gitlab/-/issues/483771

This reverts commit e065a3116a.
This reverts commit c4c6a222c4.
2024-09-06 21:55:20 +02:00
Caleb Connolly e065a3116a CI: use large runner for autoupdate (MR 5498)
Since we build linux-next before pushing to BPO, use the big runner so
we don't delay the update by hours. BPO needs to build it *again* too...

would be nice if we could push the artifact directly, ah well.

Signed-off-by: Caleb Connolly <caleb@postmarketos.org>
2024-08-15 18:49:20 +02:00
Oliver Smith f9ef1ba850 CI: kconfigcheck.toml change: check all kernels (MR 5391)
When the kconfigcheck.toml file changes, let CI check all kernels
against the modified kconfigcheck.toml file.
2024-07-29 19:57:03 +02:00
Caleb Connolly c4c6a222c4 CI: use more gitlab.com runners (MR 5236)
We have access to the fancy runners since GitLab.com donate premium to
us. There's no downside to making the most of them while we can. We
don't depend on them, but they'll make our CI go zoom!

For the next few months until we migrate to self-hosted :D

Signed-off-by: Caleb Connolly <caleb@postmarketos.org>
2024-07-11 23:05:55 -07:00
Caleb Connolly d934985209 CI: implement scheduled auto-update pipeline (MR 4967)
Introduce support for having CI automatically update packages using
project access tokens and scheduled pipelines.

The pipeline schedule is configured with an additional variable
containing a list of packages to update, the autoupdate-fetch.sh script
then calls a handler for each of these, the handler is expected to check
for an update, make the necessary APKBUILD changes and commit them.

After all packages have been updated, the changes are pushed to pmaports
master using a project access token.

[ci:skip-build] takes too long to build in CI
2024-06-19 22:45:20 +02:00
Stefan Hansson fcf8026c83 CI: use latest (stable) Alpine instead of Edge (MR 5174)
Alpine 3.20 has released now which should contain everything we need to
run our CI.

Closes https://gitlab.com/postmarketOS/pmaports/-/issues/2747
[ci:skip-build]: already built successfully in CI
2024-05-27 13:33:23 -07:00
Stefan Hansson 5db3273820 CI: stop adding testing repository to Ruff check (MR 5039)
Ruff is now in community in Alpine Edge.

[ci:skip-build]: already built successfully in CI
2024-05-01 00:54:49 +02:00
Stefan Hansson 3249af6333 CI: run wiki check on changed .gitlab-ci.yml (MR 5039)
Useful to check that changes to the CI definition actually work.
2024-05-01 00:54:49 +02:00
Vitaliy Ognev b8f8f8dec1 ci: always update docker image packages (MR 5038) 2024-04-16 09:46:11 +03:00