Skip to content

Added validator for folder permissions - #1824

Merged
andrewnester merged 10 commits into
mainfrom
feature/validate-folder-permissions
Oct 24, 2024
Merged

Added validator for folder permissions#1824
andrewnester merged 10 commits into
mainfrom
feature/validate-folder-permissions

Conversation

@andrewnester

@andrewnesterandrewnester commented Oct 10, 2024

Copy link
Copy Markdown
Contributor

Changes

This validator checks permissions defined in top-level bundle config and permissions set in workspace for the folders bundle is deployed to. It raises the warning if the permissions defined in the workspace are not defined in bundle.

This validator is executed only during bundle validate command.

Tests

Warning: untracked permissions apply to target workspace path
The following permissions apply to the workspace folder at "/Workspace/Users/andrew.nester@databricks.com/.bundle/clusters/default" but are not configured in the bundle:
- level: CAN_MANAGE, user_name: andrew.nester@databricks.com

Comment threadbundle/config/validate/folder_permissions.go Outdated
Comment threadbundle/config/validate/folder_permissions.go Outdated
Comment threadbundle/config/validate/folder_permissions.go Outdated
Comment threadbundle/config/validate/folder_permissions.go Outdated
Comment threadbundle/config/validate/folder_permissions.go
Comment threadbundle/config/validate/folder_permissions.go Outdated
Comment threadbundle/config/validate/folder_permissions.go Outdated
Comment threadbundle/config/validate/folder_permissions.go Outdated
Comment threadbundle/config/validate/folder_permissions.go Outdated
Comment threadbundle/config/validate/folder_permissions.go
Comment threadbundle/config/validate/folder_permissions.go Outdated
Comment threadbundle/config/validate/folder_permissions.go
Comment threadbundle/config/validate/folder_permissions.go
Comment threadbundle/permissions/check.go Outdated
Comment threadbundle/permissions/check.go Outdated
Comment threadbundle/permissions/check.go Outdated
Comment threadbundle/permissions/check.go Outdated
Comment threadbundle/permissions/check.go Outdated
Comment threadbundle/config/validate/folder_permissions.go Outdated
Comment threadbundle/config/validate/folder_permissions_test.go Outdated
Comment threadbundle/config/validate/folder_permissions_test.go Outdated
Comment threadbundle/config/validate/folder_permissions_test.go Outdated
Comment threadbundle/permissions/check.go Outdated
Comment threadbundle/permissions/check.go Outdated
Comment threadbundle/permissions/check.go Outdated
Comment threadbundle/config/resources/permission.go
andrewnesterand others added 4 commits October 16, 2024 15:32
Co-authored-by: Pieter Noordhuis <pieter.noordhuis@databricks.com>
Co-authored-by: Pieter Noordhuis <pieter.noordhuis@databricks.com>
Comment threadbundle/config/validate/folder_permissions.go
Comment threadbundle/permissions/check.go
Comment threadbundle/permissions/check.go
Comment threadbundle/permissions/check.go Outdated
Comment threadbundle/permissions/check.go Outdated

@pieternpietern left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remaining things:

  • Please update the PR summary before merging
  • Figure out how to compose this with #1821 (I now get two warnings that are essentially the same)

@andrewnester
andrewnester added this pull request to the merge queueOct 24, 2024
Merged via the queue into main with commit eaea308Oct 24, 2024
@andrewnester
andrewnester deleted the feature/validate-folder-permissions branch October 24, 2024 12:45
andrewnester added a commit that referenced this pull request Oct 30, 2024
New features for Databricks Asset Bundles:
This release adds support for managing AI/BI dashboards as part of your bundle configuration. The `bundle generate` command is updated to support producing dashboard bundle configuration as well as dashboard payloads.
You can find an example configuration and walkthrough at https://github.com/databricks/bundle-examples/tree/main/knowledge_base/dashboard_nyc_taxi
Bundles:
* Add support for AI/BI dashboards ([#1743](#1743)).
* Added validator for folder permissions ([#1824](#1824)).
* Add bundle generate variant for dashboards ([#1847](#1847)).
* Use SetPermissions instead of UpdatePermissions when setting folder permissions based on top-level ones ([#1822](#1822)).
Internal:
* Attempt to reduce test flakiness on Windows ([#1845](#1845)).
* Reuse resource resolution code for the run command ([#1858](#1858)).
* [Internal] Automatically trigger integration tests on PR ([#1857](#1857)).
* Add privacy notice to README ([#1841](#1841)).
* [Internal] Add test instructions for external contributors ([#1863](#1863)).
* Add `libs/dyn/jsonsaver` ([#1862](#1862)).
Dependency updates:
* Bump github.com/fatih/color from 1.17.0 to 1.18.0 ([#1861](#1861)).
github-merge-queueBot pushed a commit that referenced this pull request Oct 30, 2024
**New features for Databricks Asset Bundles:**
This release adds support for managing AI/BI dashboards as part of your
bundle configuration. The `bundle generate` command is updated to
support producing dashboard bundle configuration as well as a serialized
JSON representation of the dashboard.
You can find an example configuration and walkthrough at
https://github.com/databricks/bundle-examples/tree/main/knowledge_base/dashboard_nyc_taxi
CLI:
* Add privacy notice to README
([#1841](#1841)).
Bundles:
* Add support for AI/BI dashboards
([#1743](#1743)).
* Added validator for folder permissions
([#1824](#1824)).
* Add bundle generate variant for dashboards
([#1847](#1847)).
* Use SetPermissions instead of UpdatePermissions when setting folder
permissions based on top-level ones
([#1822](#1822)).
Internal:
* Attempt to reduce test flakiness on Windows
([#1845](#1845)).
* Reuse resource resolution code for the run command
([#1858](#1858)).
* [Internal] Automatically trigger integration tests on PR
([#1857](#1857)).
* [Internal] Add test instructions for external contributors
([#1863](#1863)).
* Add `libs/dyn/jsonsaver`
([#1862](#1862)).
Dependency updates:
* Bump github.com/fatih/color from 1.17.0 to 1.18.0
([#1861](#1861)).
---------
Co-authored-by: Pieter Noordhuis <pieter.noordhuis@databricks.com>
denik pushed a commit that referenced this pull request May 20, 2026
## Changes
This validator checks permissions defined in top-level bundle config and
permissions set in workspace for the folders bundle is deployed to. It
raises the warning if the permissions defined in the workspace are not
defined in bundle.
This validator is executed only during `bundle validate` command.
## Tests
```
Warning: untracked permissions apply to target workspace path
The following permissions apply to the workspace folder at "/Workspace/Users/andrew.nester@databricks.com/.bundle/clusters/default" but are not configured in the bundle:
- level: CAN_MANAGE, user_name: andrew.nester@databricks.com
```
---------
Co-authored-by: Pieter Noordhuis <pieter.noordhuis@databricks.com>
denik pushed a commit that referenced this pull request May 20, 2026
**New features for Databricks Asset Bundles:**
This release adds support for managing AI/BI dashboards as part of your
bundle configuration. The `bundle generate` command is updated to
support producing dashboard bundle configuration as well as a serialized
JSON representation of the dashboard.
You can find an example configuration and walkthrough at
https://github.com/databricks/bundle-examples/tree/main/knowledge_base/dashboard_nyc_taxi
CLI:
* Add privacy notice to README
([#1841](#1841)).
Bundles:
* Add support for AI/BI dashboards
([#1743](#1743)).
* Added validator for folder permissions
([#1824](#1824)).
* Add bundle generate variant for dashboards
([#1847](#1847)).
* Use SetPermissions instead of UpdatePermissions when setting folder
permissions based on top-level ones
([#1822](#1822)).
Internal:
* Attempt to reduce test flakiness on Windows
([#1845](#1845)).
* Reuse resource resolution code for the run command
([#1858](#1858)).
* [Internal] Automatically trigger integration tests on PR
([#1857](#1857)).
* [Internal] Add test instructions for external contributors
([#1863](#1863)).
* Add `libs/dyn/jsonsaver`
([#1862](#1862)).
Dependency updates:
* Bump github.com/fatih/color from 1.17.0 to 1.18.0
([#1861](#1861)).
---------
Co-authored-by: Pieter Noordhuis <pieter.noordhuis@databricks.com>
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

@andrewnester@pietern