Open maxr-cyera opened 2 months ago
When creating an IP access list using the CLI, it is created with enabled: false regardless of the enabled parameter.
enabled: false
enabled
Please list the steps required to reproduce the issue, for example:
databricks account ip-access-lists create --json '{"list_type":"ALLOW","enabled":true,"ip_addresses":["0.0.0.0/32"],"label":"test"}'
The created list enabled state should align with the parameter.
The state is always false regardless of the parameter value.
Sonoma 14.5, Databricks CLI v0.224.0
No
18:00:47 INFO start pid=2971 version=0.224.0 args="databricks, account, ip-access-lists, create, --json, {\"list_type\":\"ALLOW\",\"enabled\":true,\"ip_addresses\":[\"0.0.0.0/32\"],\"label\":\"test1\"}, --debug" 18:00:47 DEBUG /Users/max/.databrickscfg has no DEFAULT profile configured pid=2971 sdk=true Using account profile: account-admin 18:00:48 DEBUG Loading account-admin profile from /Users/max/.databrickscfg pid=2971 sdk=true 18:00:48 INFO Ignoring pat auth, because databricks-cli is preferred pid=2971 sdk=true 18:00:48 INFO Ignoring basic auth, because databricks-cli is preferred pid=2971 sdk=true 18:00:48 INFO Ignoring oauth-m2m auth, because databricks-cli is preferred pid=2971 sdk=true 18:00:48 INFO Refreshed OAuth token from Databricks CLI, expires on 2024-07-24 18:17:35.029517 +0300 IDT pid=2971 sdk=true 18:00:48 DEBUG Using Databricks CLI authentication with Databricks OAuth tokens pid=2971 sdk=true 18:00:48 INFO Refreshed OAuth token from Databricks CLI, expires on 2024-07-24 18:17:35.029517 +0300 IDT pid=2971 sdk=true 18:00:49 DEBUG POST /api/2.0/accounts/ACCOUNT_ID/ip-access-lists > { > "ip_addresses": [ > "0.0.0.0/32" > ], > "label": "test1", > "list_type": "ALLOW" > } < HTTP/2.0 200 OK < { < "ip_access_list": { < "address_count": 1, < "created_at": 1721833249635, < "created_by": userID, < "enabled": false, <------ False is being sent even though the parameter is true < "ip_addresses": [ < "0.0.0.0/32" < ], < "label": "test1", < "list_id": "07e46c7e-d404-4b2e-8cb7-8a51438c8b78", < "list_type": "ALLOW", < "updated_at": 1721833249635, < "updated_by": userID < } < } pid=2971 sdk=true { "ip_access_list": { "address_count":1, "created_at":1721833249635, "created_by":userID, "enabled":false, "ip_addresses": [ "0.0.0.0/32" ], "label":"test1", "list_id":"07e46c7e-d404-4b2e-8cb7-8a51438c8b78", "list_type":"ALLOW", "updated_at":1721833249635, "updated_by":userID } }
This is related to this issue in Go SDK https://github.com/databricks/databricks-sdk-go/issues/1002
Describe the issue
When creating an IP access list using the CLI, it is created with
enabled: false
regardless of theenabled
parameter.Steps to reproduce the behavior
Please list the steps required to reproduce the issue, for example:
databricks account ip-access-lists create --json '{"list_type":"ALLOW","enabled":true,"ip_addresses":["0.0.0.0/32"],"label":"test"}'
Expected Behavior
The created list enabled state should align with the parameter.
Actual Behavior
The state is always false regardless of the parameter value.
OS and CLI version
Sonoma 14.5, Databricks CLI v0.224.0
Is this a regression?
No
Debug Logs