LXC-Web-Panel icon indicating copy to clipboard operation
LXC-Web-Panel copied to clipboard

Import improvement from robvdl fork

Open claudyus opened this issue 11 years ago • 8 comments

This thread is to track improvement that could be imported from the robvdl fork, otherwise we cannot simple cherry-pick commits due to his deep app rework.

claudyus avatar Aug 25 '14 18:08 claudyus

https://github.com/robvdl/LXC-Web-Panel/commit/318ad33642afbc8424bc1a8dcf28ac1f531a2b04

claudyus avatar Aug 25 '14 18:08 claudyus

https://github.com/robvdl/LXC-Web-Panel/commit/e1a379d8ff0589c5b3f5790a5333849821cdbd46

claudyus avatar Aug 25 '14 18:08 claudyus

https://github.com/robvdl/LXC-Web-Panel/commit/0d4a9fcfc16328d80768b18de7ccc2cf661b6892

claudyus avatar Aug 25 '14 18:08 claudyus

https://github.com/robvdl/LXC-Web-Panel/commit/e10facbc35f675ff4a3c12faf5820ba3c16df551 investigate uppercase in check_ubuntu

claudyus avatar Aug 25 '14 18:08 claudyus

https://github.com/robvdl/LXC-Web-Panel/commit/09d161d8ad37e70352d0fd4214e882fca979818c

claudyus avatar Aug 25 '14 21:08 claudyus

Migrate to wtform as per https://github.com/robvdl/LXC-Web-Panel/issues/31, investigate for ipv4/mad validation

TODO after 0.7 release

claudyus avatar Aug 31 '14 13:08 claudyus

Claudyus: The edit form is almost done, I've also added in a few fields that I noticed you added recently, these are:

id_map, hook_pre_start, hook_pre_mount, hook_mount, hook_start, hook_post_stop and hook_clone

I am pretty sure these new fields are working (saving) correctly, I ended up added them to the form as I noticed they were defined in code, but not yet in the form.

There is still one experimental thing I am trying right now in another branch of my repo, and that is to unify the backend validation regex, and pattern on the from end... if it works (I am not sure yet)

Then, I am hoping I can automatically generate the front-end pattern from the backend regex, so you only need to the define the regex once per field. In most cases, the JavaScript regex style is compatible with Python's anyway.

When this is all done, I am happy to help bring all this WTForm work into your repo, and do this in a branch on your repo so you can look at it.

I suggest the bit where I am using my SQLAlchemy models to update the bucket token, to just use your existing SQL queries as I don't really want to bring in both the forms and the model stuff at once.

robvdl avatar Sep 21 '14 20:09 robvdl

One of the things that I am having to deal with, is that sometimes complexity of the front end regex (for example utsname) is greater (so generally better and more accurate), but sometimes the backend regex is better.

So as I am unifying the regexes I need to basically decide which one is best, if the backend and front end regexes are different.

robvdl avatar Sep 21 '14 20:09 robvdl