Ask Your Question
0

puppet 6 package jdk & jdk1.8 install

asked 2018-10-16 17:49:55 -0600

billjamzz2 gravatar image

I'm testing puppet 6 to see what module changes I need. One thing I've found is package behaves differently. Trying to install jdk & jdk1.8 on same system. With puppet 5.2.0-1 it works fine because it does "Debug: Executing '/bin/yum -d 0 -e 0 -y install jdk'". Wtil puppet 6.0.2 it doesn't work becuase it does "Debug: Executing: '/bin/rpm -q jdk --nosignature --nodigest --qf '%{NAME} %|EPOCH?{%{EPOCH}}:{0}| %{VERSION} %{RELEASE} %{ARCH}\n' --whatprovides'" which tries to install jdk1.8 instead of jdk-1.7.

How do I install jdk and jdk1.8 in puppet 6? I tried "package {'jdk': ensure => '1.7.0_79-fcs'" but it tried to run: "Debug: Executing: '/bin/yum -d 0 -e 0 -y downgrade jdk-1.7.0_79-fcs'" which is not what I asked for.

How do I get puppet 6 to use yum instead of "rpm --whatprovides"?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-10-22 17:11:37 -0600

billjamzz2 gravatar image

updated 2018-11-21 11:57:36 -0600

I guess the only way to install jdk 7 and jdk 8 on a server is to use an exec for jdk7. Unfortunate.

Another method only works for centos 6, not centos 7: package {'jdk': ensure => '1.7.0_80', } (can't use "latest" here any more) package{'jdk1.8': ensure => latest, }

for centos7 this works: package {'jdk': ensure => '1.7.0_79-fcs', provider => 'rpm', source => 'http://path-to-rpm/jdk-7u79-linux-x64.rpm', } package {'jdk1.8': ensure => latest }

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2018-10-16 17:49:55 -0600

Seen: 172 times

Last updated: Nov 21 '18