Automatically stage new and updated users

Elliot Paynter asked on January 12, 2023 17:07

I can see from this question (https://devnet.kentico.com/questions/staging-users) that it’s possible to filter staging to show only user related items. My question is whether it’s possible to automate the synchronisation of users in staging. I believe the built in auto sync only works with pages.

Thanks

Correct Answer

Brenden Kehren answered on January 12, 2023 17:38

You are correct the auto-sync only works for content related items. From a security standpoint, you should NOT have user accounts in non-production systems, it is NOT a good practice and can open your systems up to major security risks. This is true with any site, in any CMS.

To answer your question, you can create a custom scheduled task to sync objects on a scheduled basis. You're essentially rewriting the process already in place for pages. You can use the API to access the staging logs, then look for specific object types and sync them over.

0 votesVote for this answer Unmark Correct answer

Recent Answers


Elliot Paynter answered on January 12, 2023 17:43

Appreciate the quick answer. My users are imported from an SFTP feed - Im going to take your advice and import them directly into Production, so the custom scheduled task won’t be necessary in this case but thanks anyway.

0 votesVote for this answer Mark as a Correct answer

Juraj Ondrus answered on January 13, 2023 11:19

Just for reference, if anyone will be looking for such a scheduled task, we have a KB article on this topic available here.

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.