Hello,
I installed and configured an HTTP Marketplace for my ON 5.0.2.
I would like to have two http servers.
I would like to create Apps and have image files saved in both http servers. Is that possible?
If I add the server ip in BRIDGE_LIST attribute, is the right way to proceed?
If I understand the question, I think you need to define two Marketplaces:
NAME = market1
MARKET_MAD = http
BASE_URL = "http://<url_market_1>/"
PUBLIC_DIR = "/path/to/dir/market_1" # <- this is where files will be written to
BRIDGE_LIST = "server_market_1" # <- this is the server where the files are being written to
And a similar one for market2.
if BRIDGE_LIST is empty, file list will be stored in PUBLIC_DIR in the frontend, and they must be accessible via http in the address that contains BASE_URL. If BRIDGE_LIST is defined, it will store them in that server, instead of in the frontend.
OK, now I get it. Unfortunately that is not supported. The script will get one of the hosts in BRIDGE_LIST randomly and copy the file only to that server. If you want to change the behaviour it can be done with a little bit of hacking.
List only one server in BRIDGE_LIST and distribute the files asynchronously with an rsync that is triggered using inotify. This should be done outside of OpenNebula. I believe you want to do this because you have a load balancer in front of the nodes, so you must take into account that OpenNebula will finish the register operation before the files are properly distributed to all the hosts. So doing a GET may fail while the distribution process is finished. I think I would go for option 1.