Define Job Inputs and Secrets
mainTork jobs support dynamic values through inputs and sensitive data through secrets.
Inputs
Use the inputs block to define variables that can be referenced in tasks using the {{ inputs.key_name }} syntax.
Secrets
Use the secrets block for sensitive information. These values are automatically redacted in API responses. Reference them in tasks using the {{ secrets.key_name }} syntax.
Note: When passing secrets to a task's environment, use the expression language to map them to environment variables.
name: my job
inputs:
source: https://example.com/path/to/video.mov
secrets:
api_key: 1111-1111-1111-1111
tasks:
- name: my task
image: alpine:latest
env:
SOURCE_URL: '{{ inputs.source }}'
API_KEY: '{{ secrets.api_key }}'
run: curl -X POST -H "API_KEY: $API_KEY" http://example.com