The way it should work is:
- foreman keeps track if a rex job was execute through a particular smart proxy
- if foreman determines the job goes through a specific proxy for the first time, the proxy should remove the entry from known hosts file just before trying to open the connection
- when you remove the host, the record tying a host to the smart proxy gets dropped so on next execution foreman should think that it is being executed that way for the first time
So you should see the key there, until you try running the job again