Skip to content

Commit

Permalink
Merge branch 'dev' into staging
Browse files Browse the repository at this point in the history
  • Loading branch information
dweinholz committed Feb 15, 2024
2 parents 857ef49 + 05ab8d8 commit 4484e4a
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 4 deletions.
1 change: 1 addition & 0 deletions simple_vm_client/bibigrid_connector/bibigrid_connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ def __init__(self, config_file: str):
self._BIBIGRID_PORT: str = ""
self._BIBIGRID_ANSIBLE_ROLES = []
self._BIBIGRID_LOCAL_DNS_LOOKUP = False
self._BIBIGRID_EP = ""
self._BIBIGRID_USE_MASTER_WITH_PUBLIC_IP: bool = False
self._PRODUCTION_bool = True
self.load_config_yml(config_file=config_file)
Expand Down
2 changes: 1 addition & 1 deletion simple_vm_client/config/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ bibigrid:

# FORC
forc:
activated: True
activated: False
# If Forc ist activated -- defaults to True
forc_url: https://proxy-dev.bi.denbi.de:5000/
# URL for FORC.
Expand Down
2 changes: 1 addition & 1 deletion simple_vm_client/config/config_local.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ openstack:

# Bibigrid configuration
bibigrid:
activated: False
activated: True
# If Bibigrid ist activated -- defaults to True
port: 8080
# Port number for Bibigrid API.
Expand Down
7 changes: 5 additions & 2 deletions simple_vm_client/openstack_connector/openstack_connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -966,9 +966,12 @@ def get_or_create_project_security_group(self, project_name, project_id):

def get_limits(self) -> dict[str, str]:
logger.info("Get Limits")
limits = self.openstack_connection.get_compute_limits()
limits.update(self.openstack_connection.get_volume_limits()["absolute"])
# Retrieve compute and volume limits
compute_limits = self.openstack_connection.get_compute_limits()
volume_limits = self.openstack_connection.get_volume_limits()["absolute"]

# Merge compute and volume limits into a single dictionary
limits = {**compute_limits, **volume_limits}
return {
"cores_limit": str(limits["max_total_cores"]),
"vms_limit": str(limits["max_total_instances"]),
Expand Down

0 comments on commit 4484e4a

Please sign in to comment.