Report this

What is the reason for this report?

Ruby on Rail users how to reset email for admin login

Posted on May 22, 2014

I can’t contact web person who set up site. I logged in admin using email and password to make a change on site. Not knowing anything I mistakenly deleted my email address which was the one I used to log on to admin . I believe my web guy used Rudy on Rails for the admin application. I need someone familiar with Ruby to help me reset my email for admin so I can get back into site. Certain many parts of website were custom made. the site is using Digital Ocean.



This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

@Steve: I’ll email you directly. I think I’ve got this figured out for you.

Hi Steve, <br> <br>Sorry to hear that you still haven’t figured this out. What was the result of you last efforts? <br> <br>It looks like your site uses ActiveAdmin for it administration panel. Since you still have access to the server, you should be able add a new admin user through the rails console. If you login to the server directly, change to the directory holding the rails project and run: <br> <br><pre> <br>rails console <br> </pre> <br> <br>You should now be in the rails console. Here you can create a new <br>admin user by running: <br> <br><pre> <br>u=AdminUser.new(:email => “YOUR_EMAIL”, :password => ‘YOUR_NEW_PASSWORD’, :password_confirmation => ‘YOUR_NEW_PASSWORD’) <br>u.save <br></pre>

Andrew , thank you , as I made clear , this is all Greek to me. <br>I just want to log on to my site . If I can’t do it then I have no option but shut it down and begin again. There are things on the site that need cancelled and <br>updated . Any suggestions?

The developer cloud

Scale up as you grow — whether you're running one virtual machine or ten thousand.

Get started for free

Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

*This promotional offer applies to new accounts only.