Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

This is considered a "lite" dev env since we are not cloning git, or making pull requests.  We just want to run grouper and make GSH templates or hooks or provisioners or daemons.

Note, if using Java 17, pass this argument to tests and tomcat

Code Block
--add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.sql/java.sql=ALL-UNNAMED


  1. Install Java11Install Java8Java17 (or whatever version your container runs in)
  2. Install eclipse, in installer select "Eclipse IDE for Enterprise Java and Web Developers", select the Java11 Java17 you just installed
    1. Make sure eclipse ini has at least 3 gig memory
  3. Add Java8 Java17 JRE



  4. Make a new Maven project without archetype




  5. Right click on Project, Maven → Add dependency
    1. GroupId: edu.internet2.middleware.grouper
    2. ArtifactId: grouper-ui
    3. Version: 2.5.47(whatever you use): e.g. 4.12.0




  6. Right click on project, Maven, update project
  7. I use the java perspective, so switch to that



  8. You can stop here if just coding GSH.  If coding against the UI, continue: Get the webapp dir out of container



    Code Block
    PS C:> cd C:\users\mchyzer-local\eclipse-workspace\test
    PS C:\users\mchyzer-local\eclipse-workspace\test> docker run --detach -e GROUPER_LOG_TO_HOST=true --name grouperFiles i2incommon/grouper:2.5.47 ui
    62149d4d5f784949c635ba3ebc4276fb91b11e2bc39fe77d2ce7100f4780f405
    PS C:\users\mchyzer-local\eclipse-workspace\test> docker cp grouperFiles:/opt/grouper/grouperWebapp .
    PS C:\users\mchyzer-local\eclipse-workspace\test> docker rm -f grouperFiles
    grouperFiles
    PS C:\users\mchyzer-local\eclipse-workspace\test> 
    
    


  9. Refresh your eclipse project and see grouperWebapp



  10. Lets move the existing grouperWebapp/WEB-INF/classes dir contents into a new source folder named grouperWebappClasses

  11. Move any properties files from there to the resources folder and customize.  Note if you are connecting to an existing database, the morphString secret must match

  12. If you are using a new database
    1. Start hsql

      Code Block
      PS C:\users\mchyzer-local\eclipse-workspace\test> mkdir temp
      PS C:\users\mchyzer-local\eclipse-workspace\test> cd temp
      PS C:\users\mchyzer-local\eclipse-workspace\test> java -cp .\grouperWebapp\WEB-INF\lib\hsqldb-2.3.5.jar org.hsqldb.Server -port 9001 -database file:temp/grouper



    2. grouper.hibernate.properties (moved from grouperWebappClasses)



  13. If you are using an existing database



  14. Add in to grouper.hibernate.properties that it is ui, and put in a local pass for a subject (remote database) or GrouperSystem (hsql database or remote)

    Code Block
    grouper.is.ui = true
    
    # UI basic auth is for quick start. Set to false when you migrate to shib or something else
    grouper.is.ui.basicAuthn = true
    
    grouperPasswordConfigOverride_UI_mchyzer_pass = pass
    grouperPasswordConfigOverride_UI_GrouperSystem_pass = pass



  15. Set java8 java17 for project





  16. Change build path to compile to grouperWebapp/WEB-INF/classes (except the test source and test resources).  Also dont exclude any resources.  Note, in future if you do Maven → Update project, you might have reset some of these settings




  17. Download tomcat 8.59




  18. Add a new server in eclipse



  19. Window → Show view → Servers, add a module



  20. Make a large startup timeout



  21. Start the server

  22. Go to local grouper: http://localhost:8080/grouper   (userName/pass) or whatever you put in grouper.hibernate.properties

...