Best practices for running a dev clone of OJS

I’m assuming a lot of people around here run development clones of their OJS instances and I was wondering what’s the best way of doing that using a snap shot of the production database without risk of sending off automated messages to users. We’ve had that happen in the past and it creates a lot of confusion and frustration for the editors since the data in the dev db doesn’t match production. Disabling sendmail isn’t the best option, because it makes it difficult to work on anything related to notifications, etc.

I imagine emptying any tables related to user data that doesn’t belong to admin, journal managers and editors might do the trick, but how will that affect other tables that rely on that data? Any suggestions would be great. Thanks :smile:

Hi @bart,

I typically run a query like the following against the dev copy before doing anything:

UPDATE users SET password=SHA1(CONCAT(username,username)), email=CONCAT(username, ''));

That sets everyone’s password to the same as their username, and sets their email addresses to (username)

Alec Smecher
Public Knowledge Project Team

1 Like

Brilliant! That’s exactly what I was looking for.

Thanks Alec!

To do this as an official QA environment costs less than $1 / day:

I usually just allow messages to spool to postfix on the server and read them at the terminal.