diff --git a/public/static/docs/command-reference/config.md b/public/static/docs/command-reference/config.md index aeb88b1ea0..afbb836d36 100644 --- a/public/static/docs/command-reference/config.md +++ b/public/static/docs/command-reference/config.md @@ -152,6 +152,13 @@ for more details.) This section contains the following options: > These warnings are automatically turned off when `cache.type` is manually > set. +- `cache.shared` - permissions for newly created or downloaded cache files and + directories. The default permissions are `0o664`(rw-r--r--) for files and + `0o755`(rwxr-xr-x) for directories. The only accepted value right now is + `group`, which makes DVC use `0o664`(rw-rw-r--) for files and + `0o775`(rwxrwxr-x) for directories, which is useful when you are using a a + [shared development server](/doc/use-cases/shared-development-server). + - `cache.local` - name of a local remote to use as cache directory. (Refer to `dvc remote` for more information on "local remotes".) This will overwrite the value provided to `dvc config cache.dir` or `dvc cache dir`. diff --git a/public/static/docs/use-cases/shared-development-server.md b/public/static/docs/use-cases/shared-development-server.md index 6bbd866534..f1c357c779 100644 --- a/public/static/docs/use-cases/shared-development-server.md +++ b/public/static/docs/use-cases/shared-development-server.md @@ -37,6 +37,16 @@ to simply move it from an old cache location to the new one: $ mv .dvc/cache/* /path/to/dvc-cache ``` +Now you need to ensure that cache files/directories have appropriate +permissions, so that they could be accessed by your collegues that are members +of the same group: + +```dvc +$ sudo find /path/to/dvc-cache -type f -exec chmod 0664 {} \; +$ sudo find /path/to/dvc-cache -type d -exec chmod 0775 {} \; +$ sudo chown -R myuser:ourgroup /path/to/dvc-cache/ +``` + ## Configure shared cache Tell DVC to use the directory we've set up above as an shared cache location by @@ -46,6 +56,13 @@ running: $ dvc config cache.dir /path/to/dvc-cache ``` +And tell DVC to set group permissions on the newly created/downloaded cache +files: + +```dvc +$ dvc config cache.shared group +``` + Commit changes to `.dvc/config` and push them to your git remote: ```dvc