chef-mongodb3
chef-mongodb3 copied to clipboard
mongo 3.4?
I've specified this line on my mongodb.rb
recipe:
node.default['mongodb']['package_version'] = '3.4'
include_recipe 'mongodb3::default'
Nevertheless, a 3.2.x version is installed on ghest machine.
Do I need to specify anything more?
I'm getting this message:
ERROR: yum_package[mongodb-org-server] (mongodb3::default line 26) had an error: Chef::Exceptions::Package: Version ["3.4-1.el7"] of ["mongodb-org-server"] not found. Did you specify both version and release? (version-release, e.g. 1.84-10.fc6)
Should be version
instead of package_version
Also see https://github.com/sunggun-yu/chef-mongodb3/pull/59/files
I was able to build a 3.4 server using the following variables. Using Ubuntu 14.04
default['mongodb3']['package']['repo']['apt']['key'] = '0C49F3730359A14518585931BC711F9BA15703C6'
default['mongodb3']['package']['repo']['apt']['components'] = ['multiverse']
default['mongodb3']['version'] = '3.4.4'
Has anyone had any success installing 3.4 on CentOS 7? If I set ['mongodb3']['version'] = '3.4.9', the repo file /etc/yum.repos.d/mongodb-org-3.4.repo is created. However it has the wrong url: baseurl=https://repo.mongodb.org/yum/redhat/$releasever/mongodb-org/3.2/x86_64. The 3.2 should be 3.4
If I try to force the correct url by setting _['mongodb3']['package']['repo']['url'] = 'https://repo.mongodb.org/yum/redhat/$releasever/mongodb-org/3.4/x86_64/' it still doesn't work and I end up with the same incorrect baseurl in the mongodb-org-3.4.repo.
I was upgrading an existing node from 3.2 to 3.4.
If you see 3.2 url being hardcoded, delete the existing node attributes using knife node edit <node-name>
and run chef-client. The cookbook should set new attributes to node.
Chef-client is not overriding existing 3.2 url and node attribute takes precedence to cookbook parameter. So, deleting attributes should help.
These are the attributes set to node after 3.4 Changes:
"normal": {
"tags": [
],
"mongodb3": {
"package": {
"version": "3.4.21-1.amzn1",
"repo": {
"url": "https://repo.mongodb.org/yum/amazon/2013.03/mongodb-org/3.4/x86_64/",
"apt": {
"name": "3.4",
"keyserver": null,
"key": "EA312927",
"components": null
}
}
}
}
},
Hope this helps.