Sometimes the code alone does not say where a call goes. For example, a service calls ORDERS_URL + "/orders", and the value of ORDERS_URL is only set when the program is deployed. Niro then cannot link that call to the orders service's route. These commands let you fill in what is missing, for one folder. Run each one inside the folder.

Which folders are services

niro modules

Lists the folders inside this one that Niro treats as separate services (deployables).

The settings your code reads

niro env scan                       # find the settings the code reads
niro env list                       # show them
niro env set ORDERS_URL=http://orders:8080
niro env set-from ORDERS_URL=deploy/orders.env
niro env unset ORDERS_URL
niro env files add deploy/staging.env

Niro reads the template files .env.example, .env.sample and .env.template by itself. A real env file is read only if you name it with niro env files add, and then only its address values. Passwords and tokens are refused and never stored.

The address a service answers on

niro base-url                         # show it
niro base-url http://orders:8080      # set it
niro base-url ""                      # go back to the address Niro worked out

You can also give it when adding the folder: niro init --base-url <url>.

Where a path goes, when the project does not say

niro route-rule unconnected                           # calls Niro could not link
niro route-rule add "/api/orders/*" --to orders
niro route-rule list
niro route-rule remove <id>

A rule says that calls to a path go to a given service. You can have up to 200 rules. Rules are copied to temporary projects for new branches.

Niro uses the new values at the next build. To build now, run niro build.