When I do this, I get the following error: Invalid variable reference syntax for variable cf:MyStack.devCustomerPool. Which, of course, is the correct way to reference stack outputs as defined in the docs. I have double checked that indeed MyStack does exist, and it does have an output with the key devCustomerPool. So why am I getting this error?
My problem ended up being easier/stupider I was using a global install of sls that was an old version. Once I ran the local, updated, version it worked.
Looks like an older version of Serverless didn’t parse environment variables - the syntax was being passed directly to CFN, and it obviously didn’t like it.