summaryrefslogtreecommitdiffstats
path: root/src/dbi.h
diff options
context:
space:
mode:
authorOpenGnSys Support Team <soporte-og@soleta.eu>2024-08-28 12:45:46 +0200
committerOpenGnSys Support Team <soporte-og@soleta.eu>2024-08-28 15:28:47 +0200
commitcd9650108af1eb882ca11858249dc428087667ff (patch)
tree40496a1e3c277feafd9fe2997a633c19acf52f5b /src/dbi.h
parent9ee9d66b7c7c8e1c4e5b70ccaf5dae74b31a91f9 (diff)
src: infer server IP when it has more than one IP address
infer server IP for a given client. User does not have to attach a client to a given server IP anymore through ordenadores.identorno. this simplifies previous work to allow a server to have more than one IP address a0a347068285 ('#1074 rest: set_mode: add support for different ogserver addresses') 44745a3f2287 ('rest: add POST client/server method') POST /client/server is removed, it is only used by ogcli and explicit association between server and client is not required. server_id json attribute is also removed in GET client/info.
Diffstat (limited to 'src/dbi.h')
-rw-r--r--src/dbi.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/dbi.h b/src/dbi.h
index 81eac3e..909a4bd 100644
--- a/src/dbi.h
+++ b/src/dbi.h
@@ -82,7 +82,6 @@ struct og_legacy_partition {
struct og_computer {
unsigned int procedure_id;
unsigned int hardware_id;
- unsigned int server_id;
unsigned int repo_id;
unsigned int center;
unsigned int room;
@@ -140,5 +139,7 @@ int og_dbi_schema_update(void);
int og_dbi_get_repository_ip(const struct og_dbi *dbi, const uint32_t repo_id,
const char *client_ip, char *repository_ip);
+int og_dbi_get_server_ip(const struct og_dbi *dbi, const char *client_ip,
+ char *server_ip);
#endif