22

Normally I use TDS to move Sitecore items from one environment to the next (e.g. dev to QA to stage to prod). For many sites, being able to move items is sufficient. However, some sites have specific roles that need to be moved from environment to environment.

I have been serializing and unserializing users and roles and moving those files, but that's an error-prone process.

Is there a method/tool/process to automate moving roles and users between environments?

22

TDS 5.1 added the ability to manage roles within TDS. You have to enable management of roles in TDS in the project. This is done by opening the TDS project properties and, on the General Property tab, enabling the "Manage Sitecore Roles in TDS" check box:

TDS project settings - General tab - Manage Sitecore Roles in TDS

Once you've enabled this, a folder item called "Sitecore Roles" will appear. From there, you can manage roles in much the same way as you can manage items.

Hedgehog has documented this functionality here: https://hedgehogdevelopment.github.io/tds/chapter4.html#sync-sitecore-roles.

|improve this answer|||||
1

As stated above you can use the TDS functionality to do that which works great especially for single-site instance.

What I found though if you are doing multi-site then it's getting harded to structure roles with TDS as it requires you to include all member roles as well in each TDS package and they could override each other.

In my case I ended up by creating an admin page where you can serialize/deserialize roles in JSON and this JSON will store only your custom roles. Then on a different environment you can sync the roles from the serialized content back.

I wonder if anybody had the same approach as me, but this is just an alternative solution to TDS way.

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.