mirror of
https://github.com/home-assistant/core.git
synced 2025-06-25 01:21:51 +02:00
Fix and upgrade minio integration (#84545)
closes https://github.com/home-assistant/core/issues/79842
This commit is contained in:
@ -136,8 +136,7 @@ def setup(hass: HomeAssistant, config: ConfigType) -> bool:
|
||||
file_path = _render_service_value(service, ATTR_FILE_PATH)
|
||||
|
||||
if not hass.config.is_allowed_path(file_path):
|
||||
_LOGGER.error("Invalid file_path %s", file_path)
|
||||
return
|
||||
raise ValueError(f"Invalid file_path {file_path}")
|
||||
|
||||
minio_client.fput_object(bucket, key, file_path)
|
||||
|
||||
@ -148,8 +147,7 @@ def setup(hass: HomeAssistant, config: ConfigType) -> bool:
|
||||
file_path = _render_service_value(service, ATTR_FILE_PATH)
|
||||
|
||||
if not hass.config.is_allowed_path(file_path):
|
||||
_LOGGER.error("Invalid file_path %s", file_path)
|
||||
return
|
||||
raise ValueError(f"Invalid file_path {file_path}")
|
||||
|
||||
minio_client.fget_object(bucket, key, file_path)
|
||||
|
||||
|
@ -2,7 +2,7 @@
|
||||
"domain": "minio",
|
||||
"name": "Minio",
|
||||
"documentation": "https://www.home-assistant.io/integrations/minio",
|
||||
"requirements": ["minio==5.0.10"],
|
||||
"requirements": ["minio==7.1.12"],
|
||||
"codeowners": ["@tkislan"],
|
||||
"iot_class": "cloud_push",
|
||||
"loggers": ["minio"]
|
||||
|
@ -34,7 +34,9 @@ def create_minio_client(
|
||||
endpoint: str, access_key: str, secret_key: str, secure: bool
|
||||
) -> Minio:
|
||||
"""Create Minio client."""
|
||||
return Minio(endpoint, access_key, secret_key, secure)
|
||||
return Minio(
|
||||
endpoint=endpoint, access_key=access_key, secret_key=secret_key, secure=secure
|
||||
)
|
||||
|
||||
|
||||
def get_minio_notification_response(
|
||||
|
@ -1110,7 +1110,7 @@ mill-local==0.2.0
|
||||
millheater==0.10.0
|
||||
|
||||
# homeassistant.components.minio
|
||||
minio==5.0.10
|
||||
minio==7.1.12
|
||||
|
||||
# homeassistant.components.moat
|
||||
moat-ble==0.1.1
|
||||
|
@ -812,7 +812,7 @@ mill-local==0.2.0
|
||||
millheater==0.10.0
|
||||
|
||||
# homeassistant.components.minio
|
||||
minio==5.0.10
|
||||
minio==7.1.12
|
||||
|
||||
# homeassistant.components.moat
|
||||
moat-ble==0.1.1
|
||||
|
Reference in New Issue
Block a user