Skip to content

Commit

Permalink
docs(core): tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
isaacplmann committed Nov 15, 2024
1 parent 339066c commit d0de31a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion docs/shared/deprecated/legacy-cache.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Legacy Cache

In Nx 20, the local cache metadata and project graph are stored in a database, rather than using the file system. (Cache artifacts are still stored on the file system.) In Nx 21 the legacy file system cache will be removed and the database cache will be the only option. The database cache has two benefits:
In Nx 20, the local cache metadata are stored in a database, rather than using the file system. (Cache artifacts are still stored on the file system.) In Nx 21 the legacy file system cache will be removed and the database cache will be the only option. The database cache has two benefits:

1. Cache reads and writes are faster.
2. The local cache is more secure since other processes with access to the file system can no longer read or modify the cache.
Expand Down
5 changes: 5 additions & 0 deletions docs/shared/guides/unknown-local-cache.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,11 @@ error.

## You Share Cache with Another Machine Using a Network Drive

When using the legacy file system cache ([deprecated in Nx 20](/deprecated/legacy-cache)), you can prefix any Nx command with `NX_REJECT_UNKNOWN_LOCAL_CACHE=0` to ignore the errors (
e.g., `NX_REJECT_UNKNOWN_LOCAL_CACHE=0 nx run-many -t build test`). This is similar to
setting `NODE_TLS_REJECT_UNAUTHORIZED=0` to ignore any errors stemming form self-signed certificates. Even though it
will make it work, this approach is discouraged.

Storing Nx's local cache on a network drive presents security risks, so we prevent you from doing so. When a network drive is shared, every CI run has access to all the previously created Nx cache artifacts. Hence, it is plausible for every single artifact - for every
single task hash - to be accessed without leaving any trace. This is possible due to the network drive's capability to
allow overwrites.
Expand Down

0 comments on commit d0de31a

Please sign in to comment.