Open
Description
- Module version: 6.3.1
- Puppet version: 4.10.12 and 5.5.4
- OS and version: Debian 9 and Ubuntu 18.04
Bug description
Install any old version of elasticsearch before 6.3.0 e.g.
include ::java
class { 'elasticsearch':
version => '6.2.0'
}
elasticsearch::instance { 'es-01': }
Then try to upgrade Elasticsearch to version 6.3.x. The upgrade will fail because it will try to create an initial keystore (this feature was introduced in version 6.3.0 elastic/elasticsearch#28928 ). The creating of the keystore will fail because elasticsearch-keystore doesn't find ES_PATH_CONF and exists with an errorcode.
==> puppet-test01.local: ES_PATH_CONF must be set to the configuration path
==> puppet-test01.local: dpkg: error processing package elasticsearch (--configure):
==> puppet-test01.local: installed elasticsearch package post-installation script subprocess returned error exit status 1
The problem does not happen if the initial version is already 6.3.x because then the keystore is created before ES_PATH_CONF is removed from /etc/default/elasticsearch.