openoms / joininbox

A terminal based graphical menu for JoinMarket
MIT License
153 stars 20 forks source link

Github actions: arm64-rpi image #91

Closed openoms closed 2 years ago

openoms commented 2 years ago

Done in https://github.com/openoms/joininbox/pull/89

There is one issue where the sha256sum of the image did not match the image: https://github.com/openoms/joininbox/actions/runs/2770754146/attempts/1

sha256sum -c joininbox-arm64-rpi.img.sha256 
joininbox-arm64-rpi.img: FAILED
sha256sum: WARNING: 1 computed checksum did NOT match

sha256sum joininbox-arm64-rpi.img
520ddddf8cd61997829f52cc89a7aba8c8eca4ee50e5b637eeb1da89a2effb39  joininbox-arm64-rpi.img
cat joininbox-arm64-rpi.img.sha256 
bc8fdebde4dc3998fd2cc5b32377444f5e2a2c74b87efafef09d6daecf171255    joininbox-arm64-rpi.img

It is because the image is manipulated after the hash is created:

-rw-rw-r-- 1 s s 8589934592 Jul 31 20:56 joininbox-arm64-rpi.img
-rw-rw-r-- 1 s s         89 Jul 31 20:54 joininbox-arm64-rpi.img.sha256

Might be because of keep_input_artifact = true fixing in: https://github.com/openoms/joininbox/commit/fcbada861e3f50d7f339934a16314905b388043a

openoms commented 2 years ago

92 Generate image checksum in github script solved the issue of generating the checksum with packer - likely it was done before the image was unmounted from docker.

tar -czvf joininbox-arm64-rpi.img.tar.gz joininbox-arm64-rpi.img leads to a Missing partition table error in Balena Etcher image so using xz instead. Produces a smaller image also.

Compressing with xz led to an erro in the GitHub Action:

Run cd scripts/packer/arm64-rpi/packer-builder-arm/
joininbox-arm64-rpi.img: 775.9 MiB / [8](https://github.com/openoms/joininbox/runs/7707787220?check_suite_focus=true#step:7:9)1[9](https://github.com/openoms/joininbox/runs/7707787220?check_suite_focus=true#step:7:10)2.0 MiB = 0.095, 5.8 MiB/s, 23:23
xz: joininbox-arm64-rpi.img.xz: Cannot set the file group: Operation not permitted
Error: Process completed with exit code 2.

Proceeded with gzip.

openoms commented 2 years ago

Find the link to the latest tested image in the readme: https://github.com/openoms/joininbox#set-up-using-an-sdcard-image