$ openssl req -newkey rsa:2048 -x509 -keyout test.pem -out cacerttest.pem -days 3650 ## FILL ALL THE DETAILS
$ openssl pkcs12 -export -in cacerttest.pem -inkey test.pem -out identity.p12 -name "mykey"
Use the key identity.p12
and configure it over server.xml
in tomcat
Run the docker compose file to deploy sample war over TLS
docker-compose up -d