Commit Graph

100 Commits

Author SHA1 Message Date
Ricardo Pardini
f8ddf7f9e2 🔥 JSON info pipeline: v18
- pipeline: add `pipeline` context object to targets; use it to filter artifacts and images to build; warn about oci-name with multiple oci-tags
- pipeline: better error messages when info's fail; show some (out-of-order) progress messages during parallel info gathering
- pipeline: targets-compositor: add `not-eos` inventory
- TARGETS_FILENAME, log all OCI lookups
- SKIP_IMAGES
- IMAGES_ONLY_OUTDATED_ARTIFACTS
- no dash in chunk id in JSON
- pipeline: very initial chunking, using the same outputs
- pipeline: template targets, `items-from-inventory:` inventory expansion, CHECK_OCI=yes, CLEAN_MATRIX=yes, CLEAN_INFO=yes, many fixes
- cli: `inventory` / `targets` / `matrix` / `workflow`
- pipeline: workflow beginnings
- pipeline: general log cleanup + OCI stats / better miss handling
- pipeline: fixes/reorg
- pipeline: catch & log JSON parsing errors
- pipeline: gha matrix: use IMAGE_FILE_ID as job description
- pipeline (delusion): gha workflow output, based on old matrix code
- pipeline: better parsing and reporting of stderr log lines (under `ANSI_COLOR=none`)
- pipeline: mapper-oci-uptodate: use separate positive/negative cache dirs (GHA will only cache positives); cache negs for 5 minutes locally
- pipeline: output-gha-matrix artifacts + images
  - pipeline: output-gha-matrix artifacts + images: "really" and fake 1-item matrix if empty
- pipeline: move files into subdir; update copyright & cleanup
- pipeline: refactor bash jsoninfo driver a bit
- pipeline: outdated-artifact-image-reducer
- pipeline: introduce `target_id` at the compositor, aggregate it at the reducer, carry it over in the artifact info mapper
- pipeline: mapper-oci-uptodate
- pipeline: info-gatherer-artifact, with PRE_PREPARED_HOST
- pipeline: refactor/rename info-gatherer-image.py
- pipeline: beginnings
2023-05-01 22:46:25 +02:00
Ricardo Pardini
d0716b65c0 docker/sudo: better control/info over CLI relaunch args; introduce CLI relaunch envs
- allow adding re-launch environments by populating `ARMBIAN_CLI_RELAUNCH_PARAMS` dict
- similar to `ARMBIAN_CLI_RELAUNCH_PARAMS`
- rename/consolidate `()`'s output globals:
  - `ARMBIAN_CLI_FINAL_RELAUNCH_ARGS` (rename)
  - `ARMBIAN_CLI_FINAL_RELAUNCH_ENVS` (new)
    - includes `ARMBIAN_HIDE_REPEAT_PARAMS` automatically
- `sudo`: include envs when relaunching, use bash explicitly
- `docker`: better logging
- `docker`: include envs when relaunching via `--env` args
2023-04-21 14:26:33 +02:00
Markus Hoffrogge
d1252fc0ee interactive: better Repeat Build Options [by @mhoffrog, squashed, rebased]
Add interactive configurations to Repeat Build Options

Simplify function produce_repeat_args_array()

- make use of $ARMBIAN_NON_PARAM_ARGS and $ARMBIAN_PARSED_CMDLINE_PARAMS (associated array)
- quote parameter values to be on the safe side

Move "Repeat Build Options" logs to start-end.sh

- cli-build.sh, start-end.sh:
  - move function function produce_repeat_args_array() to start-end.sh
  - add $WHAT as first arg to produce_repeat_args_array() if
    $WHAT is not empty
  - move early display log of "Repeat Build Options" to
    function main_default_start_build()
  - move last log of "Repeat Build Options" to
    function main_default_end_build()
  - add last log of "Repeat Build Options" to
    LOG_SECTION="repeat_build_options"
2023-04-21 14:26:33 +02:00
Ricardo Pardini
22059c2669 lib: shellfmt & fix gen-library to match 2023-04-18 09:27:38 +02:00
Ricardo Pardini
7ea8e040d0 cli: flash: introduce flash CLI command; introduce hook post_build_image_write 2023-04-15 22:43:06 +02:00
Ricardo Pardini
eb1fe6d7ba artifacts: introduce PRE_PREPARED_HOST=yes: allow running pre-prepared host CLI's for artifacts that require aggregation 2023-04-15 22:43:06 +02:00
Ricardo Pardini
538b8c2b79 artifacts/cli: introduce CLI command artifact-config-dump-json (alias to artifact, but sets CONFIG_DEFS_ONLY=yes)
- if CONFIG_DEFS_ONLY during `obtain_complete_artifact()`, just dump JSON to stdout after calculating version/coordinates
- don't prepare ORAS tooling if CONFIG_DEFS_ONLY
- don't run in standard build (and thus don't prepare_host()) if under CONFIG_DEFS_ONLY
- if CONFIG_DEFS_ONLY, don't run `check_basic_host()`
2023-04-15 22:43:06 +02:00
Ricardo Pardini
ed0b406265 lib: fix: replace undue export statements with declare -g 2023-03-31 09:12:44 +02:00
Ricardo Pardini
77921725fb lib: run shellfmt; remove commented-out; no actual changes 2023-03-31 09:12:44 +02:00
Ricardo Pardini
7d90b10f79 configdump: better logging; insert (still unsupported) array/dict raw value and 2do markers into produced dump JSON 2023-03-31 09:12:44 +02:00
Ricardo Pardini
d868d76182 artifacts: bsp-cli, bsp-desktop, desktop: rework, with @igorpec
- bsp-cli: does not require aggregation
- bsp-desktop / desktop: requires aggregation
- 'desktop' packaged moved out of 'bsp' folder, it is NOT a bsp
- make consistent naming/folders
- extract .sh generation workflow into 'declare -f' magic functions
- `SHOW_DEBIAN=yes` to bump most of `DEBIAN/xxx` stuff to screen
- artifact armbian-bsp-desktop: use aggregation, require certain vars, CLI forces `BUILD_DESKTOP=yes`; requires BOARD
- artifact armbian-desktop: use aggregation, require certain vars, CLI forces `BUILD_DESKTOP=yes`, not require `BOARD` anymore
- cli: commands: fix artifact aliases, reorder
- desktop/bsp-desktop: add `config_dump` method; fix `artifact_map_debs` ref subdir and name
- artifact bsps: require aggregation to build, not to list what needs to be built
- distro-agnostic: fix install of `armbian-bsp-cli` (not `armbian-bsp`)
- armbian-bsp-cli: add `_config_dump` method, use configuration with aggregation, add required vars check
- distro-specific: fix installation of `fake-ubuntu-advantage-tools`
2023-03-31 09:12:44 +02:00
Ricardo Pardini
55ba084acc configdump: include rudimentary artifact dependency information for config-dump-json (artifact implementations)
- include rudimentary artifact dependency information for config-dump-json: fixes/refactor/cleanup
- artifact-rootfs.sh: include rudimentary artifact dependency information for config-dump-json
- artifact-armbian-(config/plymouth-theme/zsh).sh: include rudimentary artifact dependency information for config-dump-json
- artifact-fake-ubuntu-advantage-tools.sh: include rudimentary artifact dependency information for config-dump-json
2023-03-31 09:12:44 +02:00
Ricardo Pardini
42fc56697b configdump/json-info-boards: revamp, all-JSON now; use_board=yes skip_kernel=no for config; refactor & use new Python bash-declare-to-JSON utility
- use new capture'd vars scheme
- so `./compile.sh BOARD=xxx BRANCH=yyyy config-dump-json | jq .` now works and is consistent/newline tolerant
- introduce internal `skip_host_config=yes` for `prep_conf_main_minimal_ni()` to skip calling `check_basic_host()`
2023-03-31 09:12:44 +02:00
Ricardo Pardini
02c561ce0e bat-cat: introduce tooling support for bat (colorized/smart cat), including DEBIAN/xxx syntaxes; cached in Docker image 2023-03-31 09:12:44 +02:00
Igor
00f849ac71 [AR-1620 + AR-1639 squashed]:: @igorpec's armbian-config/zsh/bsp/desktop/ubuntu-advantage artifacts 2023-03-31 09:12:44 +02:00
hzy
26b8642804 Bugfix: Allow to set empty cmdline params
Fix the following error:
  [🌱] Skip     cmdline param [ 'DESKTOP_APPGROUPS_SELECTED': already set to '(empty)' early ]
2023-03-26 20:54:39 +02:00
Igor
a01f764195 If OCI_TARGET_BASE is not set, then this override doesn't work 2023-03-22 10:35:36 +01:00
Igor
7a6dca2f90 Add switch 2023-03-20 13:50:33 +01:00
Ricardo Pardini
8493d91b61 check early (before running any CLI command) for old LIB_TAG usage 2023-03-17 08:32:11 +01:00
Ricardo Pardini
2f4f117000 prepare ORAS tooling early, so we don't get spurious failures "only on first build" 2023-03-17 08:32:11 +01:00
Ricardo Pardini
6b965c605c completely remove any traces of KERNEL_ONLY and exit with error if set 2023-03-17 08:32:11 +01:00
Igor Pečovnik
b7b8eb7b72
Add / modify (c) in bash scripts (#4922)
* Add / modify (c) in bash scripts

Signed-off-by: Igor <igor@armbian.com>

* Add (c) to the source config files

---------

Signed-off-by: Igor <igor@armbian.com>
2023-03-09 18:30:40 +01:00
Ricardo Pardini
d69f09d676
kernel-config: ignore artifact cache, makes no sense with make menuconfig (fixes #4854) (#4856) 2023-02-24 10:44:02 +01:00
Ricardo Pardini
9bffa5e749
armbian-next: artifacts: firmware/rootfs and actual usage of artifacts during image build
- artifacts: introduce `ARTIFACT_IGNORE_CACHE=yes`
- artifacts: introduce `DONT_BUILD_ARTIFACTS`, list of artifacts that if not found cached, fail the build
- kernel_package_source() is no more
- a long dissertation about kernels, families, and the universe
- artifacts: actually use rootfs artifact for image build
- artifacts: detangle via artifact_base_dir
- artifacts: rootfs: use folders in artifact_name; include cache_type
- artifacts: some cleanups / validations
- rootfs artifact; drop old rootfs cli
- artifacts: new CLI shortcuts; remove old firmware CLI
- artifacts: full firmware & usage
- use firmware artifacts in image build and install its debs
- kernel artifact sans legacy; use tmpdir for .deb target for all packages
- legacy artifact versions is no more; pack/unpack now in common obtain;
- artifacts: uboot: cleanup legacy renaming, use artifact version directly
- artifacts: add firmware (small) artifact
- deploy uboot to loop from artifact; allow tty to artifact; todos for cleaning
- fixes, kernel dtb/headers conditional; remove `.git` from Makefile url; use mapfile for finding files to hash
  - completely remove KERNEL_HAS_WORKING_HEADERS_FULL_SOURCE and `kernel_package_callback_linux_headers_full_source()`
  - don't use realpath for artifact_file_relative
  - curb some warnings
  - fix: only install headers & dtbs if such exist
- kernel .config hook modification hash versioning
- OCI_TARGET_BASE vs per-artifact defaults; only deploy to remote from CLI with OTB
- artifact revolver & installing into image
  - add artifact_map_packages and artifact_map_debs dicts
  - revolver accumulates all info
  - REPOSITORY_INSTALL is no more (for uboot/kernel, later others)
  - rename `VER` to `IMAGE_INSTALLED_KERNEL_VERSION`
2023-02-18 07:46:03 -03:00
Ricardo Pardini
ca6bf9046b
armbian-next: remove all traces of Vagrant and FEL boot 2023-02-18 07:46:00 -03:00
Ricardo Pardini
399d9964dd
armbian-next: python/pip: include pip pkgs in Dockerfile; use them if available instead of downloading 2023-02-18 07:45:51 -03:00
Ricardo Pardini
f0d3ea7961
armbian-next: tooling: introduce helper/downloader for shellcheck; include in Dockerfile 2023-02-18 07:45:48 -03:00
Ricardo Pardini
871f3cfcee
armbian-next: tooling: include ORAS tools in Dockerfile; use them if available instead of downloading 2023-02-18 07:45:47 -03:00
Ricardo Pardini
0e480e685e
armbian-next: docker: pass down git info via env var, since Docker doesn't get ${SRC}/.git, yet we need that info in the Docker logs 2023-02-18 07:45:40 -03:00
Ricardo Pardini
3f91b77e3f
armbian-next: docker-shell: provide SSH and forward ssh auth socket to docker-shell 2023-02-18 07:45:34 -03:00
Ricardo Pardini
6258ea566a
armbian-next: shellcheck: squash a bunch of 'critical' warnings 2023-02-18 07:45:29 -03:00
Ricardo Pardini
1fc13a57a7
armbian-next: json-info: cleanup info/json/csv/opensearch, add logging, add some very basic instructions; add Kibana dashboards & docker-compose to bring it OS+Kibana up 2023-02-18 07:45:27 -03:00
Ricardo Pardini
a7fcd44942
armbian-next: cli: u-boot alias: don't stop to interactively ask for kernel configuration during u-boot build 2023-02-18 07:45:25 -03:00
Ricardo Pardini
ba7487b1a1
armbian-next: docker: fix Dockerfile generation; don't output logs info during Dockerfile build 2023-02-18 07:45:23 -03:00
Ricardo Pardini
bb6975707a
armbian-next: take a breath: config might mark aggregation required; aggregation requires prepare_host, and thus runs in default-build 2023-02-18 07:45:21 -03:00
Ricardo Pardini
bef7f8fee4
armbian-next: artifacts: introduce kernel/u-boot artifacts; git ref2info; "memoizer"; some hashing
- artifacts: u-boot/kernel - pt7 - adapt legacy/artifact versions; use common `capture_rename_legacy_debs_into_artifacts()`
- artifacts: u-boot - pt6: add artifact for u-boot
  - use artifact version / reason in actual u-boot .deb if present
- artifacts: kernel - pt5: tune kernel version, refactor
- artifacts: kernel - pt4: squash unrelated bugs that show up; move `prepare_compilation_vars()` to default build
- artifacts: kernel - pt3: drivers+patches+.config hashing
  - split file hashing function from drivers-harness; fix it so filenames are relative and sorted; sort from ${SRC}, always
  - aplit prepare_kernel_config_core_or_userpatches() from `kernel_config_initialize()`
- artifacts: kernel - pt2:  memoizing git ref2info
- artifacts: kernel - pt1:  versioning
2023-02-18 07:45:20 -03:00
Ricardo Pardini
281e3f0828
armbian-next: cli: try (and fail, probably...) to be helpful with half-working Docker installs 2023-02-18 07:45:16 -03:00
Ricardo Pardini
d43c4262b0
armbian-next: cli: *do not* allow running as root on terminal; make PREFER_DOCKER=no actually work
- do allow root if non-interactive
2023-02-18 07:45:15 -03:00
Ricardo Pardini
aadf012464
armbian-next: do-not-fix docker-asking-for-docker error by adding a "tip" 2023-02-18 07:45:14 -03:00
Ricardo Pardini
8329b2e970
armbian-next: docker: split docker_cli_build_dockerfile() into docker_cli_prepare_dockerfile(); introduce FAST_DOCKER
- armbian-next: docker: fix hostrelease crazy
2023-02-18 07:45:11 -03:00
Ricardo Pardini
3b126c0730
armbian-next: unify 2 methods for config: prep_conf_main_minimal_ni() (rootfs/firmware/kernel) and prep_conf_main_build_single() (full-build, possibly interactive) 2023-02-18 07:45:05 -03:00
Ricardo Pardini
9dc24840c3
armbian-next: firmware-deb: reworked: Provides/Conflicts instead of Replaces; cp -> git archive; new firmware CLI; FULL version .deb out of tmpfs 2023-02-18 07:45:04 -03:00
Ricardo Pardini
16eb5eb50b
armbian-next: aggregate_packages out of main_default_start_build(); introduce assert_requires_aggregation() 2023-02-18 07:45:03 -03:00
Ricardo Pardini
67e6b010f2
armbian-next: cli-build: don't show two BOARD= repeat option 2023-02-18 07:45:02 -03:00
Ricardo Pardini
1c00d64b35
armbian-next: repeat build opts: fix missing BOARD, show both after config (for logfile) & after build 2023-02-18 07:44:58 -03:00
Ricardo Pardini
962ae65a45
armbian-next: docker: include ${SRC}/.git static via Dockerfile, for kernel-patches-to-git / archeology; use fast archeology
- include FAST_ARCHEOLOGY in call to Python, default yes; sync kernel & u-boot call
2023-02-18 07:44:54 -03:00
Ricardo Pardini
6e267f5cd1
armbian-next: docker: passthrough of the SSH agent, via Docker magic on Darwin; enable for docker-shell and kernel-patches-to-git
- don't check/verify/update SSH-related hostkey etc for git tree push
2023-02-18 07:44:53 -03:00
Ricardo Pardini
32bfcb1b68
armbian-next: rootfs: curb logging; GHA outputs rootfs_cache_id_version, rootfs_cache_id and rootfs_out_filename_relative 2023-02-18 07:44:47 -03:00
Ricardo Pardini
dbfa7329ab
armbian-next: cli: kernel cli forces KERNEL_CONFIGURE=no; @TODO this should only "default to", not force. for proper kernel cli, later 2023-02-18 07:44:44 -03:00
Igor
00bc1b4a1e
armbian-next: rootfs: introduce ROOTFS_COMPRESSION_RATIO, default 5 for general use, default 15 for rootfs CLI; fix pv | tar bug; remove GPG signing
- Remove PGP signing from the script as its done in GHA
- Also remove generating .current control file as its obsolete in this design

Co-authored-by: Ricardo Pardini <ricardo@pardini.net>
2023-02-18 07:44:42 -03:00