X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=o2common%2Fconfig%2Fconfig.py;h=9c1d610d5e50163fa88cc29552a97b8a5200e183;hb=refs%2Fchanges%2F97%2F9797%2F1;hp=690f4e95141162c1df90dbc6b95fa6185de58400;hpb=475582141a4fae0784e01cf2b9490a516fc4dcbc;p=pti%2Fo2.git diff --git a/o2common/config/config.py b/o2common/config/config.py index 690f4e9..9c1d610 100644 --- a/o2common/config/config.py +++ b/o2common/config/config.py @@ -37,7 +37,8 @@ def get_smo_ca_config_path(): def get_postgres_uri(): host = os.environ.get("DB_HOST", "localhost") - port = 54321 if host == "localhost" else 5432 + # port = 54321 if host == "localhost" else 5432 + port = 5432 password = os.environ.get("DB_PASSWORD", "o2ims123") user, db_name = "o2ims", "o2ims" return f"postgresql://{user}:{password}@{host}:{port}/{db_name}" @@ -56,7 +57,7 @@ def get_api_url(): port_external = 30205 port = port_internal if host_external is None or host_external == '' \ else port_external - return f"http://{host}:{port}" + return f"https://{host}:{port}" def get_root_api_base(): @@ -77,7 +78,8 @@ def get_o2dms_api_base(): def get_redis_host_and_port(): host = os.environ.get("REDIS_HOST", "localhost") - port = 63791 if host == "localhost" else 6379 + # port = 63791 if host == "localhost" else 6379 + port = 6379 return dict(host=host, port=port)