Table of Contents
Table of Contents | ||
---|---|---|
|
...
E-mail helpdesk AT openmrs DOT org with the following information:
- OpenMRS ID
- Redirect URL – will likely be http://localhost:8080/oauth/openmrsid/callback.
Install Required Software
...
Code Block | ||||||||
---|---|---|---|---|---|---|---|---|
| ||||||||
import org.openmrs.modulus.oauth.OpenMrsIdApi
grails.serverURL = "http://localhost:8080"
modulus {
uploadDestionation = "/tmp/uploads"
openmrsid.hostname = "https://id.openmrs.org" // set this to https://id.openmrs.org if not using local ID dashboard
}
// Overrides the default configuration in grails-app/conf/DataSource.groovy
dataSource.url = "jdbc:mysql://localhost/modulus"
dataSource.username = "root"
dataSource.password = ""
// OpenMRS ID Provider. These keys correspond to keys issued by your OpenMRS ID server.
oauth.providers.openmrsid = [
api: OpenMrsIdApi,
key: "5724816929358ea0349b1c30", // change this to the client id from dashboard
secret: "67SoaGco3th1", // change this to the secret from dashboard
successUri: "${grails.serverURL}/login/success",
failureUri: "${grails.serverURL}/login/failure",
callback: "${grails.serverURL}/oauth/openmrsid/callback",
scope: "profile"
]
// Modulus UI Client. These keys must be known by a Modulus UI client to connect.
grails.plugin.springsecurity.oauthProvider.clients = [
[
clientId: "modulus123",
clientSecret: "modulus123",
registeredRedirectUri: ["http://localhost:8083/auth-success.html"],
additionalInformation: [
name: "Dev Modulus UI",
preApproved: true
]
]
]
|
...
Delete the "failure" part of the url and fill in the form and allow access to your OpenMRS ID profile. If you get Error 500 with the message "Unsupported response types: [none]" all is good.
Go the grails serverURL, which has been set in the modulus-config.groovy file (i.e. http://localhost:8080). You should be logged in to openmrsid and it should greet you.
Installing Modulus UI
Clone the Modulus UI Repo.
...