Setting keypair based on stack id