OpenLiberty / ci.docker

Eclipse Public License 1.0
44 stars 59 forks source link

infinispan-client-setup.sh failing on yum install maven #320

Open dougbreaux opened 2 years ago

dougbreaux commented 2 years ago

Starting just a day or two ago, with the exact same Dockerfile, infinispan-client-setup.sh started reporting this error:

+ yum install -y maven
Updating Subscription Management repositories.
Unable to read consumer identity

This system is not registered with an entitlement server. You can use subscription-manager to register.

Last metadata expiration check: 0:00:21 ago on Fri 03 Jun 2022 02:37:02 AM UTC.
All matches were filtered out by modular filtering for argument: maven
Error: Unable to find a match: maven
The command '/bin/sh -c infinispan-client-setup.sh' returned a non-zero code: 1

In an internal Slack conversation, it was suggested that it might be necessary to run

yum module enable maven:3.6

And this does indeed seem to have allowed the script to succeed, although perhaps only, so far, when running only the infinispan-client stage. When running both stages, I'm not sure yet if this works. It still hasn't for my local builds with Rancher Desktop. Still to be attempted with docker build under GitHub Actions CI...

dougbreaux commented 2 years ago

To follow-up, GitHub Actions docker build is now working with this set of modified steps:

# Install Infinispan client jars
USER root
ENV VERBOSE=true
RUN yum module enable -y maven:3.6 && infinispan-client-setup.sh
#RUN infinispan-client-setup.sh
USER 1001
dougbreaux commented 2 years ago

Any follow-up on addressing this in the image? And, in the meantime, in the documentation?

dougbreaux commented 2 years ago

Surely we're not the only people hitting this issue?

kabicin commented 2 years ago

Hello, https://github.com/OpenLiberty/ci.docker/pull/330 adds yum module enable -y maven:3.6 to infinispan-client-setup.sh across all images so the original RUN infinispan-client-setup.sh can be used again. Is the issue still occuring in your local builds?

dougbreaux commented 2 years ago

We have a workaround in place, and I hadn't seen any updates here, so I hadn't tried in a bit. And looks like that PR isn't merged yet, correct?

kabicin commented 2 years ago

No problem, the build appears to be resolved on my end when enabling the module, which is why I just wanted to confirm before getting the review, so it's not merged yet, but it looks like we can proceed with this change. Thanks.