Reputation: 33
I have docker contianer that is running a free trial of some software and I need to install an app which requires JDK 8 to be installed.
Since the container is running CentOS my first inclination was simply to use YUM to install the jdk.
Unfortunately, the container is so stripped down that I don't even have basic utilities like 'which' or 'find'. It does however have the 'rpm' tool installed.
So here's how I figure I could get around this to install YUM and subsequently the jdk.
I've downloaded the CentOS iso, mounted it somewhere on the host copied the BaseOS/Packages (which contains the yum rpm) dir into the container and started issuing calls to rpm -i package.
It quickly became obvious that the number of dependencies was going to be massive and doing this manually was just not worth it.
That being said, the installation process for CentOS must do something similar, so there must be a script somewhere that knows how to install all of these rpms (or some specified subset).
Could someone point me to where I could find this script or something similar?
Or if there's an even simpler approach please let me know.
Thanks in advance.
Upvotes: 0
Views: 143
Reputation: 5427
Minimal image contains microdnf
. You should be able to run:
microdnf install yum
For more information see https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html/building_running_and_managing_containers/using_red_hat_universal_base_images_standard_minimal_and_runtimes#using_minimal_red_hat_base_images
Upvotes: 1