Research And Development Stack
This project is intended to set up a full stack of web based tools to aid in Research and Development projects/teams, including the ability to make/restore backups, and cleanly remove itself from the host server. It is intended to scale from one researcher/developer to large teams developing multiple projects.
RADStack includes the following capabilities, in layers that are abstractly named such that other solutions can be dropped in if better solutions to each need is found. These needs are listed here, with the implemented solution.
- User Authentication - OpenLDAP/PHPLDAPAdmin
- DataBase - MySQL/PHPMYADMIN
- Software Configuration Managment (SCM) - Gerrit
- Content Managment (CM) - Wordpress
- Continuous Integration (CI) - Jenkins
- Project Managment (PM) - Bugzilla
-
Clone this repository. Ensure to get the submodules.
>> git clone --recursive https://github.com/bellockk/RADStack.git -
Edit the
Define Parameterssection of the bootstrap script (located at the top of the script) to include your server settings. Note that for the remainder of this installation guide, I will refer to the default entries in the script. If you have modified the default entries, use your edited entries in the steps below. -
Log into the host machine and edit your
/etc/hostsfile to include the following entries. Note that if you have a DNS server, you can just add these sites to your DNS table instead.127.0.0.1 example.com 127.0.0.1 scm.example.com 127.0.0.1 ci.example.com 127.0.0.1 cm.example.com 127.0.0.1 pm.example.com 127.0.0.1 ldapadmin.example.com 127.0.0.1 dbadmin.example.com
-
Run the `bin/bootstrap' script. Note that docker must be installed on the server, and the user who executes this script must be a member of the docker group.
>> cd RADStack >> bin/bootstrap
-
Configure LDAP and Add the first user.
- Open a web browser and go to http://ldapadmin.example.com
- On the left side of the web page under
myldapclick theloginlink. - In the
Password:entry field, entersecret, and click theAuthenticatebutton. - In the left frame under
myldap, click the+next to the line markeddc=ldap,dc=example,dc=com. - Click the
Create new entry herelink. - In the right frame labeled
Templates:clickGeneric: Organisational Unit. - In the entry field labeled
Organisational Unit, entergroupsand push theCreate Objectbutton. - Click the
Commitbutton. - In the right frame labeled
ou=groupsclick theCreate a child entrylink. - In the right frame labeled
Templates:clickGeneric: Posix Group. - In the entry field labeled
Groupenterusersand clickCreate Object. - Click the
Commitbutton. - In the left frame labeled
myldapclick theCreate new entry herelink. - In the right frame labeled
Templates:clickGeneric: Organisational Unit. - In the entry field labeled
Organisational Unit, enterpeopleand push theCreate Objectbutton. - Click the
Commitbutton. - In the right frame labeled
ou=peopleclick theCreate a child entrylink. - In the right frame labeled
Templates:clickGeneric: User Account. - In the entry field labeled
First nameenter your first name. - In the entry field labeled
Last nameenter your last name. - In the entry field labeled
Passwordenter your password. - In the option menu labeled
GID Numberselectusers. - In the option menu labeled
Login shellselect any shell, and clickCreate Object. - Click the
Commitbutton. - In the right frame, click the
Add new attributelink. - From the option menu that appears select
Email, enter the users email, and clickUpdate Objectat the bottom of the screen. - Click the
Update Objectbutton. - In the left frame under
myldap, click the+sign next toou=groups, and click the link labeledcn=users. - In the right frame labeled
cn=usersclick the link labeledAdd new attribute. - From the option menu that appears select
memberUid, enter1000in the entry field, and clickUpdate Objectat the bottom of the screen. - Click the
Update Objectbutton.
-
Configure Software Configuration Management.
- Go to http://scm.example.com in a web browser.
- Click on the
Sign Inlink in the top right hand corner of the page. - Enter the userid and password of the account you created above. This user is now the gerrit site administrator.
-
Bind Continuous Integration to LDAP
- Go to http://ci.example.com in a web browser.
- Click on
Manage Jenkinson the left side of the page. - Click on the
Setup Securitybutton near the top right of the page. - Check the box labeled
Enable security. - In the fields that open up, under
Security RealmcheckLDAP. - In the next field that opens up, labeled
Serverenterldap://myldapand click theAdvancedbutton. - In the
root DNentry field, enterdc=ldap,dc=example,dc=com - In the
User search baseentry field, enterou=people - In the
User search filterentry field, enteruid={0} - In the
Group search baseentry field, enterou=groups - In the
Group search filterentry field, entercn={0} - In the
Manager DNentry field, entercn=admin,dc=ldap,dc=example,dc=com - In the
Manager Passwordentry field entersecret - In the
Display Name LDAP attributeentry field, entercn - In the
Email Address LDAP attributeentry field, entermail - In the
Authorizationgroup, checkLogged-in users can do anything - Click the
Savebutton at the bottom of the screen.
-
Bind Project Managment to LDAP
- Go to http://pm.example.com in a web browser.
- Click on
Log In. - In the username/password fields enter
[email protected]andsecret, and click theLog inbutton. - Click on the
urlbaselink. - In the
urlbaseentry field, enterhttp://pm.example.com/bugzilla, and click theSave Changesbutton. - In the frame on the left side of the screen, click the
LDAPlink. - In the entry field
LDAPserver, entermyldap. - In the entry field
LDAPbinddn, entercn=admin,dc=ldap,dc=example,dc=com:secret. - In the entry field
LDAPBaseDN, enterou=people,dc=ldap,dc=example,dc=com. - In the entry field
LDAPuidattribute, enteruid. - In the entry field
LDAPmailattribute, entermail. - Click the
Save Changesbutton. - In the frame on the left side of the screen, click
User Authentication. - In the group
user_verify_class, use the up/down arrows to moveLDAPto the top of the list, and moveRADIUSto the bottom. - In the group
requirelogincheck theOnbutton. - Click the
Save Changesbutton. - Log out, and log back in with ldap credentials. Note that the first login must be made with the uid/password. After that, the login can be made with the email/password or uid/password.
-
Bind Content Managment to LDAP (Under Development)
- Go to http://cm.example.com in a web browser.
- Click the
Continuebutton. - Enter an approriate value in the
Site Titleentry field. - Enter a temporary username/password/email in the appropriate fields and click the
Install WordPressbutton. - Click the
Log Inbutton. - Use your temporary username/password to log in.
- Click on the
Pluginslink on the frame on the left side of the page. - Next to the
Pluginstitle, click theAdd Newbutton. - In the
Search Pluginsentry field, enterLDAPand press enter.