Incorrect oxipng binary in aarch64 container

While setting up S3 uploads I noticed an error when running the posts:rebake_uncooked_posts task:

root@i-0c6fae6cd9e30ce73-app:/var/www/discourse# rake posts:rebake_uncooked_posts
Rebaking uncooked posts on default
oxipng worker: could not get version of oxipng at /usr/local/bin/oxipng; please provide proper binary or disable this worker (--no-oxipng argument or `:oxipng => false` through options)
        2 / 9 ( 22.2%)oxipng worker: could not get version of oxipng at /usr/local/bin/oxipng; please provide proper binary or disable this worker (--no-oxipng argument or `:oxipng => false` through options)
        9 / 9 (100.0%)
9 posts done!

The binary is there, but it’s for the wrong architecture:

root@i-0c6fae6cd9e30ce73-app:/var/www/discourse# ls -l /usr/local/bin/oxipng
-rwxr-xr-x. 1 root root 1837440 Mar  3 04:39 /usr/local/bin/oxipng
root@i-0c6fae6cd9e30ce73-app:/var/www/discourse# file /usr/local/bin/oxipng
/usr/local/bin/oxipng: ELF 64-bit LSB pie executable, x86-64, version 1 (SYSV), dynamically linked, BuildID[sha1]=74a0446ce5737d1d43032abb6df3d6996f14f156, stripped

This is running 3.1.0.beta2 (26f77f03d5).

Let me know if I can provide any additional details.

1 Like

Looks like we are downloading a pre-compiled binary for x64 independently of the arch we are building. And there are no arm64 binaries in the repo, so we will need to compile this ourselves in arm.

Tagging this as pr-welcome, change is needed in

7 Likes

I’ve submitted PR#688 for this.

4 Likes

Thanks for the PR @dlambert !

1 Like

This topic was automatically closed after 43 hours. New replies are no longer allowed.