How can I access environment variables in a Canton bootstrap script?

I’m using a Canton bootstrap script to allocate parties/users and upload DARs at startup. I’d like to make this configurable in a Docker Compose setting. Is there a way I can access environment variables from within the script, or maybe there’s a different / better way how to parametrize the boostrap script?

Use something like the following:

val fullyQualfiedDomainId = sys.env.getOrElse(“ENV_VAR_NAME”, throw new IllegalStateException(“missing required environment variable ENV_VAR_NAME”))