Does anyone know if there is a way to temporarily ...
# ask-community
j
Does anyone know if there is a way to temporarily change the prefect workspace, without changing what is saved to disk? For example, when developing I sometimes need to switch to our production workspace as it has the blocks for connecting to production targets. I copied what is in the cli for changing workspaces and that works fine, but it is permanent, which leaves my dev machine pointing to the prod workspace permanently unless I remember to switch it back
s
The easiest way to have that environment separation you are looking for would be using the profile to switch between workspaces, and having the necessary blocks to be used on that workspace
If you are looking for even better security practice on blocks, I would recommend using object access control lists to have stricter permissions on the blocks that can be used on a per workspace basis
c
@Jessica Smith you can provide the settings as environment variables and they will take precedence over the profile saved to disk