Commit Graph

12 Commits (53846dccff7eb3fef993398b6d4523b2e953e58d)

Author SHA1 Message Date
Paul Spooren f7a375b9dc switch $TYPE logic to work during tests
THe recent changes were a bit short-sighted, not putting into
consideration all labels and different behaviour during testing. This
final commit should fix building for all versions, be it snapshot, a
release snapshot or a regular point release.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2021-02-27 23:26:59 -10:00
Paul Spooren 93cf40e2d1 use build job names again for TARGET/ARCH
GitLab CI seem to lose some variables when creating downstream jobs,
revert the changes back to use the job name for target/arch and apply
the rule to SDK testing.

Remove leading `deploy` from build jobs so they are better readable in
the GitLab UI. Use the leading build name as TYPE variable, so that SDKs
are not labeled on target base and imagebuilder/rootfs is not labeled
based on arch.

For `generate_targets.sh`, instead of exporting BRANCH as env variable,
use functions.sh to set it automatically. Export the `VERSION` one
globally instead of for each downstream job. This works after removing
the `gitlab-ci.yml` variable which would previously overwrite
(strangely) the downstream job settings.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2021-02-26 21:47:49 -10:00
Paul Spooren ca13177b56 simplify ARCH/TARGET variables
Instead of extracting ARCH/TARGET from the build name explicitly export
the variables to simplify the code. If not, it requires extra handling
for tagging which nulls the "simplification".

Signed-off-by: Paul Spooren <mail@aparcar.org>
2021-02-24 11:56:25 -10:00
Paul Spooren 329e5ec69d fixup generate_targets.sh branch detections
Use the functions.sh branch detection which can handle `-SNAPSHOT`.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2021-02-23 20:52:20 -10:00
Paul Spooren bc917bfb33 add OpenWrt branch as tag
this simplifies the CI testing

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-12-28 10:29:44 -10:00
Paul Spooren b24eb19785 add downstream dependencie and quote version
The VERSION variable is still missing in downstream jobs even though the
documentation states it could be added like that. Add the VERSION to the
trigger job and also quote it, to avoid possible YAML parsing issues.

Adding a *depend* to the triggered job makes the CI report the
downstream success state instead of instantly marking the upstream job
as success. Meaning, if a downstream SDK or IB job fails, the upstream
job is marked as failed.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-09-13 10:20:58 -10:00
Paul Spooren 750df8e0ae add VERSION to individual jobs
Neither pipeline nor global variables are passed to downstream jobs, add
them individually per job even if it is always the same version.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-09-11 09:02:38 -10:00
Paul Spooren b16454f65b pass VERSION env to downstream jobs
GitLab calls dynamically created jobs "downstream". They don't seem to
inherit any env variables from the main CI job, therefore add the
VERSION variable specifically.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-09-10 23:03:59 -10:00
Paul Spooren 961306c0a0 remove minor release from version
The OpenWrt branches only contains the major number

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-09-10 22:01:09 -10:00
Paul Spooren c3b582b50e version fixup
BRANCH was missing in the generate_targets.sh script.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-09-10 21:04:49 -10:00
Paul Spooren ca9e4c93d6 generate_targets: adapt to dump script name
The `dumpinfo.pl` script is now part of upstream openwrt.git but was
renamed to `dump-target-info.pl` to have a more verbose name.

Reflect that in the `gen_targets.sh` scripts.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-08-04 07:35:26 -10:00
Paul Spooren ab85512508 dynamic downstream job creation based on targets
Instead of having a hard coded list of available targets, this approach
makes use os the dumpinfo.pl script that automatically finds available
targets existing in the OpenWrt buildroot. The advantage is to
automatically adapt to available targets in different branches.

Additionally the tagging of SDK containers is improved. While it is
still possible to use SDK based on target tag, it is now also possible
to chose the target based on architecutre. This way less SDK container
are build as one architecutre covers multiple targets.

Signed-off-by: Paul Spooren <mail@aparcar.org>
2020-08-03 09:10:16 +02:00