cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
cancel
Showing results for 
Search instead for 
Did you mean: 

How to copy the content of a repos, in the workspace/shared, automatically, daily?

yopbibo
Contributor II

How to copy the content of a repos, in the workspace/shared, automatically, daily?

Purpose here is to bring some notebooks, in shared, available to all workspace users, without requesting users to use REPOS.

1 ACCEPTED SOLUTION

Accepted Solutions

yopbibo
Contributor II

finally did it with devops, was easy actually.

View solution in original post

6 REPLIES 6

Debayan
Esteemed Contributor III
Esteemed Contributor III

Hi,

In the Add Repo dialog, click Clone remote Git repo and enter the repository URL. Select your Git provider from the drop-down menu, optionally change the name to use for the Databricks repo, and click Create. The contents of the remote repository are cloned to the Databricks repo.

Please refer: https://docs.databricks.com/repos/work-with-notebooks-other-files.html#clone-a-remote-git-repository

Please let us know if you need further clarification on the same.

hi,

Thanks!

but I did that already 🙂

My question was more like if it is possible to copy the content of a repo into a folder in the shared area of the workspace.

yopbibo
Contributor II

finally did it with devops, was easy actually.

Akshay2
New Contributor II

Hi, could you share a bit I am struggling with the same problem, would be much appreciated!

using a release pipeline in devops. there is a predefined task we can use to deploy notebooks into a workspace. I trig it on pull request.

image

citizenkrank
New Contributor II

Alternatively, you can schedule a notebook with the following cell:

%sh
cp -r /Workspace/Repos/username/repo_name /Workspace/Shared

Please note that you'll have to update (i.e. pull) the repo manually if you've updated it somewhere else (although you can also schedule that with the Databricks Repos API).