diff options
| -rw-r--r-- | lib/license/management/shell.rb | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/license/management/shell.rb b/lib/license/management/shell.rb index 7baa6ba..9053a3f 100644 --- a/lib/license/management/shell.rb +++ b/lib/license/management/shell.rb @@ -48,6 +48,7 @@ module License Dir.glob('custom.*.crt').each do |path| full_path = File.expand_path(path) execute([:openssl, :x509, '-in', full_path, '-text', '-noout']) + keystore_path = "#{ENV['JAVA_HOME']}/jre/lib/security/cacerts" execute([ :keytool, '-importcert', @@ -56,12 +57,12 @@ module License '-trustcacerts', '-noprompt', '-storepass', 'changeit', - '-keystore', "#{ENV['JAVA_HOME']}/jre/lib/security/cacerts" + '-keystore', keystore_path ]) execute([ :keytool, '-list', '-v', '-storepass changeit', - '-keystore', "#{ENV['JAVA_HOME']}/jre/lib/security/cacerts" + '-keystore', keystore_path ]) end end |
