linstor-gateway
linstor-gateway copied to clipboard
Linstor gateway command upgrade is ignoring -c connect string
Linstor gateway command upgrade is ignoring -c connect string
root@node-4:~# linstor-gateway -c http://1.2.3.4:8080 nfs upgrade linstor-nfs
ERRO[0000] failed to upgrade drbd options: failed to get resource definition: Get "http://localhost:3370/v1/resource-definitions/linstor-nfs": dial tcp 127.0.0.1:3370: connect: connection refused
The upgrade commands do not actually connect to the linstor-gateway server but rather to LINSTOR directly. I can see how that behavior is counter-intuitive, but there is a technical reason for it.
The correct way to use the command is to supply a list of LINSTOR controllers to try to connect to. You can do that by:
- Putting a list of controllers in
/etc/linstor-gateway/linstor-gateway.toml:[linstor] controllers = [ "1.2.3.4:3370" ] - Setting the
LS_CONTROLLERSenvironment variable to a comma-separated list of controllers - Or using the
--controllersflag of theupgradecommand to supply the same comma-separated list.
Thanks for the report, I'll think of a way to make this more evident in the documentation.