Skip to content

Setting Up Your First Admin User

jkim-ru edited this page Oct 23, 2017 · 1 revision

In development mode (based off of the commit):

Once your application is running for the first time, you'll need to get your first admin user into the system. There isn't a great way of doing this yet. (TODO: Find a cleaner way to do this.) For now, you'll have to follow these steps:

  1. Register via http://localhost:3000/users/sign_up

  2. Set your user to "approved" status via sqlite3.

    $ sqlite3 db/development.sqlite3
    SQLite version 3.7.17 2013-05-20 00:56:22
    Enter ".help" for instructions
    Enter SQL statements terminated with a ";"
    sqlite> update users set approved = 't' where id = 1;
    sqlite> .quit
    
  3. Add your user's email to the config/role_map.yml. You'll need to restart your server after modifying this file.

    development:
      admin: 
        - your-email@example.org 
    
  4. Login as the user.

  5. Create the Fedora Object associated with the user. To do this, click on "Administration" at the top of the application. Click on "Manage Users" on the left. Click on "Create Person" in the Operations section for your user.