Failed to create Logstash keystore Only PrivateKey storage is supported

Hi,
I am trying to create the logstash keystore to store the keys, whenever I try to create the store I get the below mentioned error. I am attaching the logs from the error. I am logged in as root when I try to install on the docker pod. I see an sero byte empty file created under /etc/logstast directory called logstash.keystore.
[ERROR] 2020-05-11 03:39:38.093 [main] secretstorecli - Failed to create Logstash keystore. {:cause=>java.security.KeyStoreException: Only PrivateKey storage is supported., :backtrace=>["org.logstash.secret.store.backend.JavaKeyStore.create(org/logstash/secret/store/backend/JavaKeyStore.java:93)", "org.logstash.secret.store.backend.JavaKeyStore.create(org/logstash/secret/store/backend/JavaKeyStore.java:40)", "org.logstash.secret.store.SecretStoreFactory.doIt(org/logstash/secret/store/SecretStoreFactory.java:111)", "org.logstash.secret.store.SecretStoreFactory.create(org/logstash/secret/store/SecretStoreFactory.java:75)", "org.logstash.secret.cli.SecretStoreCli.deleteThenCreate(org/logstash/secret/cli/SecretStoreCli.java:188)", "org.logstash.secret.cli.SecretStoreCli.create(org/logstash/secret/cli/SecretStoreCli.java:179)", "org.logstash.secret.cli.SecretStoreCli.command(org/logstash/secret/cli/SecretStoreCli.java:67)", "java.lang.reflect.Method.invoke(java/lang/reflect/Method.java:498)", "org.jruby.javasupport.JavaMethod.invokeDirectWithExceptionHandling(org/jruby/javasupport/JavaMethod.java:426)", "org.jruby.javasupport.JavaMethod.invokeDirect(org/jruby/javasupport/JavaMethod.java:293)", "usr.share.logstash.lib.secretstore.cli.<module:SecretStoreCli>(/usr/share/logstash/lib/secretstore/cli.rb:35)", "usr.share.logstash.lib.secretstore.cli.<main>(/usr/share/logstash/lib/secretstore/cli.rb:16)", "java.lang.invoke.MethodHandle.invokeWithArguments(java/lang/invoke/MethodHandle.java:627)", "org.jruby.Ruby.runScript(org/jruby/Ruby.java:857)", "org.jruby.Ruby.runNormally(org/jruby/Ruby.java:780)", "org.jruby.Ruby.runNormally(org/jruby/Ruby.java:798)", "org.jruby.Ruby.runFromMain(org/jruby/Ruby.java:610)", "org.jruby.Main.doRunFromMain(org/jruby/Main.java:412)", "org.jruby.Main.internalRun(org/jruby/Main.java:304)", "org.jruby.Main.run(org/jruby/Main.java:234)", "org.jruby.Main.main(org/jruby/Main.java:206)"]}
command I am running to create the keystore file.
/bin/sh -c '/usr/share/logstash/bin/logstash-keystore --path.settings /etc/logstash create'