also, i was wondering : to get ssm var into my env...
# help
l
also, i was wondering : to get ssm var into my env, as we used that heavily in serverless, should I just : `process.env.COGNITO_CLIENT_ID = ssm.StringParameter.valueForStringParameter( this,
ssm.eu-central-1:/${_app_.stage}/COGNITO_CLIENT_ID
, );` ?
f
You want to set the environment variables so you can access it in your CDK code?
l
more from within my lambda code, the way we declare environment in a serverless.yml, to link ssm params to in-lambda env vars
f
ah yeah.. that’s how I would do it
l
however declaring env var in the lib's typescript won't make it available in my lambdas right ?
My bad, there is a
environment
key in the CDK function construct
f
Ah yup.. i think we need a doc on this