armbian-build/lib/functions/artifacts
Ricardo Pardini 622ef30f3c adapt obtain_complete_artifact() and friends to new reversioned scheme; introduce UPLOAD_TO_OCI_ONLY=yes for deploying to remote cache
> tl-dr: only deploys to remote OCI if `UPLOAD_TO_OCI_ONLY=yes`; stop leaving junk behind in local cache in many situations

- simplify CLI artifact building parameters and behaviour
    - `ARTIFACT_USE_CACHE` is now deprecated, and its behaviour is the default
    - for _any_ uploading to OCI to occur, `UPLOAD_TO_OCI_ONLY=yes` **must** be present; in this case, reversioning is not done
    - `FORCE_ARTIFACTS_DOWNLOAD` is completely removed (use `download-artifact` instead)
    - `cli_obtain_complete_artifact()`'s and `build_artifact_for_image()`'s reversioning is now moved to common `obtain_complete_artifact()`
- `standard_artifact_reversion_for_deployment()`:
    - check for hashed deb existence only if reversioned does not exist
    - touch the reversioned file if it already exists; helps to clean up junk later
    - delete hashed version after reversioning, so we don't leave trash behind
        - unless in `download-artifact` mode, which `touch`es the hashed version
        - we can later delete old files from packages-hashed to keep junk under control
- refactor `obtain_complete_artifact()`
    - extract function `artifact_dump_json_info()` since obtain is large enough already
    - when deploying to remote, always ignore all local and remote caches
    - introduce `artifact_is_available_in_revisioned_local_cache()`
        - if not deploying to remote, and revisioned cache exists, use it directly
        - if deploying to remote, reversioned is not checked and not created
    - if deploying to remote, force `DEB_COMPRESS=xz`
    - if deploying to remote, completely remove the local cache base dir after upload is done (no more junk leftover)
2023-08-12 09:58:32 +02:00
..
artifact-armbian-base-files.sh hashed-OCI-revisioned-debs: introduce "reversioning" of .deb packages 2023-08-12 09:58:32 +02:00
artifact-armbian-bsp-cli.sh hashed-OCI-revisioned-debs: introduce "reversioning" of .deb packages 2023-08-12 09:58:32 +02:00
artifact-armbian-bsp-desktop.sh hashed-OCI-revisioned-debs: introduce "reversioning" of .deb packages 2023-08-12 09:58:32 +02:00
artifact-armbian-config.sh hashed-OCI-revisioned-debs: introduce "reversioning" of .deb packages 2023-08-12 09:58:32 +02:00
artifact-armbian-desktop.sh hashed-OCI-revisioned-debs: introduce "reversioning" of .deb packages 2023-08-12 09:58:32 +02:00
artifact-armbian-plymouth-theme.sh hashed-OCI-revisioned-debs: introduce "reversioning" of .deb packages 2023-08-12 09:58:32 +02:00
artifact-armbian-zsh.sh hashed-OCI-revisioned-debs: introduce "reversioning" of .deb packages 2023-08-12 09:58:32 +02:00
artifact-fake-ubuntu-advantage-tools.sh hashed-OCI-revisioned-debs: introduce "reversioning" of .deb packages 2023-08-12 09:58:32 +02:00
artifact-firmware.sh hashed-OCI-revisioned-debs: introduce "reversioning" of .deb packages 2023-08-12 09:58:32 +02:00
artifact-full_firmware.sh hashed-OCI-revisioned-debs: introduce "reversioning" of .deb packages 2023-08-12 09:58:32 +02:00
artifact-kernel.sh hashed-OCI-revisioned-debs: introduce "reversioning" of .deb packages 2023-08-12 09:58:32 +02:00
artifact-rootfs.sh hashed-OCI-revisioned-debs: get completely rid of artifact_prefix_version 2023-08-12 09:58:32 +02:00
artifact-uboot.sh hashed-OCI-revisioned-debs: introduce "reversioning" of .deb packages 2023-08-12 09:58:32 +02:00
artifacts-obtain.sh adapt obtain_complete_artifact() and friends to new reversioned scheme; introduce UPLOAD_TO_OCI_ONLY=yes for deploying to remote cache 2023-08-12 09:58:32 +02:00
artifacts-registry.sh introduce armbian-base-files artifact, which downloads & repacks base-files from upstream distro 2023-05-18 20:49:06 +02:00
artifacts-reversion.sh adapt obtain_complete_artifact() and friends to new reversioned scheme; introduce UPLOAD_TO_OCI_ONLY=yes for deploying to remote cache 2023-08-12 09:58:32 +02:00