[英]Puppet - Unable to locate package oracle-java8-installer
我正在使用Puppet spantree / java8模塊在Vagrant hashicorp/precise32
計算機中安裝Java 8
。 在安裝時,我遇到以下異常:
==> default: Notice: /Stage[main]/Java8/File[/tmp/java.preseed]/ensure: defined content as '{md5}1b89c67b59fa03a9210a7b22a6b51b92'
==> default: Notice: /Stage[main]/Apache/Package[apache2]/ensure: ensure changed 'purged' to 'present'
==> default: Notice: /Stage[main]/Java8/Apt::Ppa[ppa:webupd8team/java]/Exec[add-apt-repository-ppa:webupd8team/java]/returns: executed successfully
==> default: Notice: /Stage[main]/Java8/File[/etc/profile.d/set_java_home.sh]: Dependency Package[oracle-java8-installer] has failures: true
==> default: Error: Execution of '/usr/bin/apt-get -q -y -o DPkg::Options::=--force-confold install oracle-java8-installer' returned 100: Reading package lists...
==> default: Building dependency tree...
==> default: Reading state information...
==> default: E: Unable to locate package oracle-java8-installer
==> default: Error: /Stage[main]/Java8/Package[oracle-java8-installer]/ensure: change from purged to present failed: Execution of '/usr/bin/apt-get -q -y -o DPkg::Options::=--force-confold install oracle-java8-installer' returned 100: Reading package lists...
==> default: Building dependency tree...
==> default: Reading state information...
==> default: E: Unable to locate package oracle-java8-installer
==> default: Warning: /Stage[main]/Java8/File[/etc/profile.d/set_java_home.sh]: Skipping because of failed dependencies
我預測行號有問題。 -文件init.pp中有 48個 :
ubuntu: {
include apt
apt::ppa { 'ppa:webupd8team/java': }
package { 'oracle-java8-installer':
responsefile => '/tmp/java.preseed',
require => [
Apt::Ppa['ppa:webupd8team/java'],
File['/tmp/java.preseed']
],
}
知道如何解決嗎?
PS:我正在使用librarian-puppet
從Puppet forge下載spantree / java8模塊。
通過確保在添加新的ppa后運行apt-get update
終於能夠通過錯誤傳遞錯誤-這是我在java8/manifests/init.pp
:
ubuntu: {
include apt
apt::ppa { 'ppa:webupd8team/java': }
exec { 'apt-update':
command => "/usr/bin/apt-get update",
require => [
Apt::Ppa['ppa:webupd8team/java']
],
}
package { 'oracle-java8-installer':
responsefile => '/tmp/java.preseed',
require => [
Exec['apt-update'],
File['/tmp/java.preseed']
],
}
}
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.