Versions Compared

Key

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

Can be used for running folio backend modules with IntelliJ Idea and further interaction with other modules running inside Vagrant box.

Step-by-step guide

1 Set IPv4 Address as on the picture below. 

 Open Host Network Manager in Oracle VM VirtualBox Manager (File → Host Network Manager or CTRL + H)

    

Add follolwing line to the vagrant file

Code Block
config.vm.network "private_network", ip: "10.0.2.15", auto_config: false


Note: The 10.0.2.15 is Guest OS IP address, so you are able to make a call to the guest OS (where is running the FOLIO).

...

5. Run an application configured in a step 3

6. Add your ModuleDescriptor. POST  /_/proxy/modules

Copy ModuleDescriptor.json from target folder as is. No headers needed.

7. Add your DeploymentDescriptor. POST  /_/discovery/modules.


Code Block
languagejs
titleDeployment descriptor example
{
  "srvcId": "mod-users-bl-5.1.0-SNAPSHOT",
  "instId": "5382d723-def7-4eeb-a301-48ec15f9bebe",
  "url": "http://10.0.2.2:8080"
}

...

url with your module address instead of launch descriptor. Use port specified in the step 3 instead of 8080 and following host http://10.0.2.2


Notes:

The field "nodeId" in the json body is not needed as we have specified the url where the module is located

...