adamant-sandwich-39749
09/27/2022, 7:16 PMContainerTask  as env vars ?
https://docs.flyte.org/projects/cookbook/en/latest/auto/core/containerization/raw_container.htmlthankful-minister-83577
mount_requirement option not working?thankful-minister-83577
thankful-minister-83577
@task(
    secret_requests=[
        Secret(
            group=SECRET_GROUP,
            key=SECRET_NAME,
            mount_requirement=Secret.MountType.ENV_VAR,
        )
    ]
)
def secret_file_task() -> Tuple[str, str]:
    # SM here is a handle to the secrets manager
    sm = flytekit.current_context().secrets
    f = sm.get_secrets_file(SECRET_GROUP, SECRET_NAME)
    secret_val = sm.get(SECRET_GROUP, SECRET_NAME)
    # returning the filename and the secret_val
    return f, secret_valthankful-minister-83577
thankful-minister-83577
thankful-minister-83577
adamant-sandwich-39749
09/27/2022, 8:38 PMsecurity_ctx