Its hard to do a reprex for this, so I'll do my best to explain.
I have a mixture of scripts and functions in a utils.R file as part of a package. All its content is intended to be for internal use and not exported. One line is causing me headaches.
but this doesn't make any difference. How can I get the assignment to be made against the env. variables on the machine (usually a Docker container) that the package is deployed to?
One trick that might help (assuming that I am answering to the right question) is to create an environment variable with new.env() and update values inside that environment using .onLoad() or .onAttach() Ref: http://r-pkgs.had.co.nz/r.html
and then you'll just have to get it's current value with t1.label(). (because the environment variable can change, you'll get whatever the current value is at the time you call the function).
Or if you want to run this code when a package loads, you can also set up an .onLoad function for your package. Some thing like