Kibana server is not ready yet

am actually trying to setup a HOME Lab and following a particular blog

and if you can have a look at this too as after the following changes like adding the xpack.security and following lines to both kibana and elasticsearch.yml file am receiving Unable to Connect error and kibana automatically stops after few minutes