How can I scope variables in Octopus Deploy to a tenant tag?

We’re in the process of setting up a fairly complicated n-tenant deployment process for a multi-application project. Is it possible to scope variables to tags?

We may have multiple tenants per ‘cluster’ of infrastructure, and the easiest/cleanest way for us to define the infrastructure that a tenant will use (not deployment targets, connection strings to other services) would be to use one tag per cluster, then assign the necessary variable values (connection strings etc.) to those tags.

This answer can be split into two buckets.

  1. Sharing common variables between tenants in a project or variable set.
    In this case, you can open up the editor when selecting the scope.

Then you can select the tenant tag and value.



2. Sharing the same variable across multiple projects but it unique per tenant.

In this case, you would leverage the project variables in the library variable sets.

Once that is created each tenant will be required to enter that value.