Skip to main content

secret

The secret directive allows a process to access secrets.

For example:

process hello_secret {
secret 'MY_ACCESS_KEY'
secret 'MY_SECRET_KEY'

script:
"""
your_command --access \$MY_ACCESS_KEY --secret \$MY_SECRET_KEY
"""
}

Each secret is provided to the task as an environment variable.

See Secrets for more information.

note

Secrets can only be used with the local or grid executors (e.g., Slurm or Grid Engine). Secrets can be used with AWS Batch and Google Batch when launched from Seqera Platform.