Skip to content

Upgrade alpine and remove customisation for JNA in the fits image. #215

@nigelgbanks

Description

@nigelgbanks

The following has been merged in aports:

https://gitlab.alpinelinux.org/alpine/aports/-/merge_requests/34087

Which should fix the issue where we had to have customisation to the jna packages for fits to support arm builds.

After upgrading to 3.15.5 when it releases we should be able to cleanup:

RUN --mount=type=bind,from=build,source=/packages,target=/packages \
--mount=type=bind,from=build,source=/etc/apk/keys,target=/etc/apk/keys \
apk add /packages/java-jna-*.apk && \
cleanup.sh
COPY --from=download --chown=tomcat:tomcat /opt/tomcat /opt/tomcat
COPY --from=download --chown=tomcat:tomcat /opt/fits /opt/fits
# Replace linux shared libraries with ones that target muslibc and are platform specific.
# Also add perl for exiftool, and platform specific jna so native libs can be loaded.
RUN --mount=type=cache,id=fits-apk,sharing=locked,from=cache,target=/var/cache/apk \
apk add \
file \
libmediainfo \
libzen \
perl \
&& \
cp $(realpath /usr/share/java/jna.jar) /opt/fits/lib && \
cleanup.sh

And remove the custom build: https://github.com/Islandora-Devops/isle-buildkit/tree/main/fits/build.

This will require testing on arm to validate that fits is working properly when calling out to native code.

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions