-
-
Notifications
You must be signed in to change notification settings - Fork 72
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
[WIP][backward-conversion] Recognize templates #100 #152
base: master
Are you sure you want to change the base?
Conversation
86cbaeb
to
dfb90d9
Compare
dfb90d9
to
0ccc26c
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
-
please reword the question because I have not understood it 100%
-
ideally we should store only what changes, this may imply to tweak the validation system, not sure (eg: if we only store one key and many other keys are required, how does that play? In theory if the validation happens on the merged configuration of config+templates, the validation should not complain).
@nemesisdesign sorry, I read it and I haven't explained it enough. Basically, consider the case:
Hence, I think for #100 we need to consider this case as well. I hope I am able to explain the problem now. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's some problems:
user deletes something that is in a template on openwisp: we can't subtract something from a template currently
user deletes something that is in the device config on openwisp: we could find a way to delete it from openwisp as well, but it would not be consistent with the previous point
Moreover, implementing the mechanism which recognizes local changes in openwisp-config and sends it back to openwisp will require some thought.
I wouldn't attempt at doing everything in this phase.
Right now we should focus on getting the basics covered and iterate according to the feedback we get from users.
For these reasons, at the moment we should just assume OpenWISP will override the local configuration, which can be sent only during registration for example, is limited but it's something we can achieve soon and nonetheless a great step forward
0ccc26c
to
57856c6
Compare
Usage
Todo
Questions
If someone sets some information, say, an interface in a template and apply it to the device and later remove that interface from luci, It will be resend by the controller and appear again on the device because it still exists in the template. How should be promote users from removing information from just their devices?
In an array like section, say interfaces, if only one value of a member, say
mtu
of interface is changed, do I copy the entire interface or just themtu
value with interface name?Currently copying the entire thing because I feel it should be stored together. (Same for "radios" section)
Closes #100