Spot Instance code working