How to move from 2 node cluster to single node?

Hello,
I've two nodes configured like this: indices replica is 1.

#define node 1 as master-eligible:
node.master: true

#define nodes 2 and 3 as data nodes:
node.data: true

#ingest mode
node.ingest: true

#define node 1 as master-eligible:
node.master: false

#define nodes 2 and 3 as data nodes:
node.data: true

#ingest mode
node.ingest: true

How to change to single cluster mode or standalone by stopping node 2 (slave) ? I would like step-by-step please. Kibana interface is enabled.

Thanks.

Solved, followed this: How to move from 3 node cluster to single node - #4 by leandrojmp

PUT _cluster/settings
{
  "persistent" : {
    "cluster.routing.allocation.exclude._ip" : "NODE-IP"
  }
}

PUT /*/_settings
{
 "index" : {
  "number_of_replicas":0,
  "auto_expand_replicas": false
 }
}

Removed node-2 references in elasticsearch.yml

Restart ES.

Stopped node 2 ES then shutdowned server.

Solved.