Create a new admin user?

I created what I thought was an admin user for my new ContinuaCI installation, but when i login the user does not have any admin privileges and can’t create any new projects. There is no Create Project button nor does the project creation wizard show up.

Is there a way to reset the admin user or create another/new one? It’s pretty useless for me at this time if I can’t create anything.

Thanks.

Hi Jerrad,

We’d be interested in the steps taken to get into this situation.  If there is not at least one administrator user, Continua redirects to the Welcome page where you can then register user details for the administrator. Also all the user and group editing functions are set up so that you cannot remove the last administrator. Is it possible that there is another administrator user other than the one you are logging in as? Can you log in as that user? If so you can then go to the administration -> users page and add the first user to the administrators group.

If this is a new install with no projects set up, then the easiest solution would be to reinstall Continua. Choose the option “I want to update my existing settings” in the setup wizard. If you are using the bundled PostgreSQl database, when you click next on the Database step, you will be given the option to delete and recreate the database - click Yes.

Otherwise you will need to edit the database directly. Ensure that you shutdown the Continua CI Server service and backup the database first. Changes to the database are generally unsupported and we cannot be responsible for any data loses.

To access the bundled PostgreSQL database, run the pgAdmin3 tool which is in the c:\Program Files\VSoft Technologies\ContinuaCI\Server\PostgreSQL\bin folder by default. The connection details are in C:\Program Files\VSoft Technologies\ContinuaCI\Server\Continua.Server.Service.exe.config under 

<hibernate-configuration>/<session-factory>/<property name=“connection.connection_string”>.

Run the query tool from the Tools menu. Execute the query:

SELECT * FROM core_user WHERE username = your_user_name;

Note the id of your user. This will be used instead of user_id below. Execute the query:

SELECT * FROM core_securityentitygroup WHERE securityentityid = user_id;

Check if a groupid of ‘00000000-0000-0000-0002-000000000002’ is listed in the results. If it is then this user is already an administrator and we have another problem… If not, run the following query to make the user an administrator.

INSERT INTO core_securityentitygroup (securityentityid, groupid) VALUES (user_id, ‘00000000-0000-0000-0002-000000000002’);


Thank you. I was able to successfully run the query’s provided and change the groupid of my user to be an admin. After that, i was successfully able to login and now have all the admin rights and tasks available.

One item to note with my experience is that when I ran the first query to get the user name from core_user, nothing returned when I gave it my username. There was no user returned at all even though I could login with that user. I had to to run SELECT * FROM core_user to see any users in the system. Once I got the uuid, I was able to run the next few querys to change the groupid. Before the change it was 00000000-0000-0000-0002-000000000001 for my username in question.

Thanks for the quick response however, and I am back in business.