Forum Discussion

safrasmusthafa's avatar
safrasmusthafa
Frequent Visitor
7 months ago
Solved

fabric git with vs code

I have the Fabric and Data Engineering extensions in VS Code, which allow me to add Fabric items like notebooks and warehouses and push them directly to a Fabric workspace. Instead, I want to restric...
  • v-veshwara-msft's avatar
    v-veshwara-msft
    7 months ago

    Hi safrasmusthafa ,

    Thanks for the follow up and thanks svenchio for providing your valuable guidance on this.

    Below is some more detail on the pattern that was mentioned, since there is no native way to block direct publish from VS Code when a user has edit access to a Fabric workspace.

     

    The main idea is to separate development work from controlled deployment.

    You can create one or more Git enabled dev or sandbox workspaces. In these workspaces, developers have full edit access. They can create Fabric items such as notebooks, pipelines, lakehouses, and warehouses using VS Code or the Fabric portal, and then push their changes to feature branches in Git or Azure DevOps. These workspaces are used only for development and are not meant for production.

     

    In parallel, you maintain a single integration or production workspace. In this workspace, regular users do not have edit access. This prevents direct changes from VS Code, the portal, or APIs.

    Updates to the integration workspace happen only through Git integration. Usually, this workspace is linked to a protected branch like main, and updates are done using UpdateFromGit, either by a small set of admins or through automation using a service principal.

    With this setup, developers can work freely, but the controlled workspace can only be updated through Git.

     

    svenchio , please confirm if this matches what you meant, or add any corrections or extra details if needed.

     

    Hope this helps, please reach out for further assistance.
    Thank you.