Skip to main content

Hutch Agent

This section shows the options that can used in a production environment as well as a development environment. It also gives a brief description along with the variable's type. The variables will default to the value in the "Default" column if one is specified. Variables with no default value must be provided yourself. Variables marked with (Required) must be given or Hutch will not work.

Hutch can be configured using the following source in the usual .NET way, in order of precedence:

  • appsettings.json adjacent to the binary (HutchAgent.dll)
  • Environment Variables (with double underscore __ as a hierarchical separator)
  • Command line arguments
  • (.NET User Secrets in development)

Available options​

Paths​

Variable nameDescriptionTypeDefault
WorkingDirectoryBaseHutch's working directorystring$HOME/hutch-workdir
JobsSub-directory for per-job working directoriesstringjobs

Queue​

Variable nameDescriptionTypeDefault
Hostname(Required) The URL to the RabbitMQ instance hosting the queuestring
Port(Required) The port for the RabbitMQ instanceint
UserName(Required) The username for the RabbitMQ instancestring
Password(Required) The password the RabbitMQ instancestring

JobActionsQueueOptions​

Variable nameDescriptionTypeDefault
QueueNameThe name of the job queuestringWorkflowJobActions
PollingIntervalSecondsHow often Hutch checks the queue for new Actionsint5
MaxParallelismHow many actions from the queue will Hutch run concurrentlyint10

StoreDefaults​

Variable nameDescriptionTypeDefault
HostThe URL to your S3 storage (e.g. MinIO)stringlocalhost:9000
AccessKey(Required) The access key to your S3 storagestring
SecretKey(Required) The secret key to your S3 storagestring
SecureAccess your S3 using HTTPS?booltrue
Bucket(Required) The name of your S3 storage bucketstring

IdentityProvider​

Variable nameDescriptionTypeDefault
ClientId(Required) The ID of your client on your OAuth2.0 providerstring
ClientSecret(Required) The secret of your client on your OAuth2.0 providerstring
Username(Required) Your username on your client on your OAuth2.0 providerstring
Password(Required) Your password on your client on your OAuth2.0 providerstring

Serilog​

Use these settings to configure HutchAgent's logging behaviour.

Variable nameDescriptionTypeDefault
UsingThe sinks to send your logging outputstring[]["Serilog.Sinks.Console"]
Enrichstring[]["FromLogContext", "WithThreadId"]
MinimumLevelArguments for the minimum logging levelobjectsee here
WriteToOptions for output sinksobject[]see here

MinimumLevel default​

{
"Default": "Information",
"Override": {
"Microsoft.Hosting.Lifetime": "Information",
"Hutch": "Information",
"Microsoft": "Warning",
"System": "Warning"
}
}

WriteTo default​

[
{
"Name": "Console",
"Args": {
"outputTemplate": "[{Timestamp:HH:mm:ss} {Level:u4}] {Message:lj} <s:{SourceContext}>{NewLine}{Exception}",
"theme": "Serilog.Sinks.SystemConsole.Themes.AnsiConsoleTheme::Code, Serilog.Sinks.Console"
}
}
]

WorkflowExecutor​

Variable nameDescriptionTypeDefault
ExecutorPathThe path to where the executor is installedstring$HOME/WfExS-backend
VirtualEnvironmentPathThe path to activate the executor's virtual environmentstring$HOME/WfExS-backend/.pyWEenv/bin/activate
LocalConfigPathThe path to the local configuration file of the executorstring"$HOME/WfExS-backend/local_config.yaml"
ContainerEngineThe name of the container engine to run workflows (can be docker, singularity or podman)stringdocker

Development-only​

Variable nameDescriptionTypeDefault
SkipExecutionUsingOutputFileThe file to use to spoof a workflow executionstring
SkipFullProvenanceCrateSkip producing the full provenence crate? Calls WfExS without --full if trueboolfalse
RemainAttachedRemain attached to the executor rather than run in the background?boolfalse

ConnectionStrings​

Variable nameDescriptionTypeDefault
ConnectionStrings__AgentDbThe connection string for Hutch's internal databasestringData Source=HutchAgent.db

Authorisation​

Variable nameDescriptionTypeDefault
DisableAuthDisables app authorisationbooleanfalse

HTTPS redirection​

Variable nameDescriptionTypeDefault
DisableHttpsRedirectionDisables HTTPS redirectionbooleanfalse

ControllerApi​

Variable nameDescriptionTypeDefault
ControllerApi__BaseUrl(Required) The base URL for the TRE controllerstring

CratePublishing - Publisher​

Variable nameDescriptionTypeDefault
IdThe identifier (typically a URL) for the Publisher in Results Cratesstring

CratePublishing - License​

Variable nameDescriptionTypeDefault
UriThe URI to the license e.g. https://spdx.org/licenses/CC-BY-4.0string

CratePublishing - License - Properties​

Variable nameDescriptionTypeDefault
IdentifierThe short-form of the license e.g. CC-BY-4.0string
NameThe long-form name of the license e.g. Creative Commons Attribution 4.0 Internationalstring

Feature flags (Development-only)​

Flags​

Variable nameDescriptionTypeDefault
StandaloneModeHutch will skip TRE Controller interactionsboolfalse
RetainFailuresHutch will not clean up working directories or database records for jobs that failboolfalse
UseOidcHutch will not use OIDC for authboolfalse

Examples​

appsettings.json​

"IdentityProvider": {
"ClientId": "my-client-id",
"ClientSecret": "my-client-secret",
"Username": "Alice",
"Password": "AlicesPassword"
}

Environment variables​

IdentityProvider__ClientId=my-client-id
IdentityProvider__ClientSecret=my-client-secret
IdentityProvider__Username=Alice
IdentityProvider__Password=AlicesPassword

.NET User Secrets​

"IdentityProvider:ClientId": "my-client-id"
"IdentityProvider:ClientSecret": "my-client-secret"
"IdentityProvider:Username": "Alice"
"IdentityProvider:Password": "AlicesPassword"