You should be able to accomplish your use case in DTM. For example, you could use a page load rule with conditional logic to ensure the user is on the correct domain before firing the tag. You could also have a page load rule that fires regardless of which domain the user is on but dynamically injects a value into the tag. This approach would require a bit of custom coding in the custom section of your rule though.