Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Store should be immutable #194

Open
wants to merge 1 commit into
base: spec
Choose a base branch
from
Open

Store should be immutable #194

wants to merge 1 commit into from

Conversation

zkochan
Copy link
Collaborator

@zkochan zkochan commented Jan 9, 2017

Added a section about store immutability.

I see two possibilities to achieve it: copying and hard linking. However, hard linking would allow editing... Howeverm, it is a huge space saver, so I really would love to keep the option of linking

@billiegoose
Copy link
Collaborator

@zkochan There's more than two possibilities! Here's all the one's I've thought of till now:

  • copying
  • hard linking
  • filesystem emulation at the OS level (i.e. FUSE)
  • filesystem manipulation at the node level (hijack the 'fs' module)
  • require manipulation at the node level (hijack the 'require' module)

There are various pros and cons that I haven't mentally sorted out yet. Some of them are install time manipulations (hard linking) while others require a runtime modification (hijacking the 'require' module). I'm leaning toward trying hijacking the 'require' module myself, but I simply have not had time.

p.s. Hard-linking only allows edits if the file permissions allow edits. My suggestion would be to have a separate user 'node' be the store owner and allow others only read+execute permissions.

Sign up for free to 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