Discovery with ECS, Dynamic Initial Master Nodes

Yes, that looks about right (except discovery.zen.hosts_provider -> discovery.seed_providers).

Note that you wouldn't set cluster.initial_master_nodes at all on any other nodes in this case.

You might also like to call this API before shutting the election node down:

POST /_cluster/voting_config_exclusions/election_node

and then this after it's gone:

DELETE /_cluster/voting_config_exclusions

That'll make sure that the cluster is ready to lose this node before it goes away. Otherwise there's a risk that you shut it down too soon leaving the other nodes without a master.