PHP webscripts

Hi guys,

I noticed the PHP scripts on github and I think it's cool to see how much work you guys did there for the webpanel. I also think there is some room in the PHP scripts to improve in terms of code quality and structure. Are there any plans for rewriting / improving that part? I would love to volunteer to do some work there, maybe a light-weight PHP framework could help the code further?

Edit: This is outdated information, PHP will be around for longer now.

We're trying to move away from PHP, GitHub - pi-hole/web: Pi-hole Dashboard for stats and more is the new version we'd like to develop.

Ok and for the backend logic will also transfer to some other programming language / framework?

Ah ok I see it now, it's a react project. Is there also some API docs thingy like swagger to see what endpoints are provided for the web interface?

Not really, the API is inside of pihole-FTL, GitHub - pi-hole/FTL at new/http is the branch.

Uses GitHub - civetweb/civetweb: Embedded C/C++ web server

(Edit: There is an older API that we no longer are pursing at GitHub - pi-hole/api: The Pi-hole API)

There is this open PR, it's questionable if it gets merged at some point, though

Ok understandable.

So I started the new web environment on localhost. I think the technical set-up of the new dashboard is really good (redux, react etc cool stuff) but I don't feel the strategy to build the "old" thingy in new technology. Was there any discussion earlier on how the new dashboard should look like? And in version 6, is there a switch to switch from the old to the new dashboard and visa versa or will this be a big-bang transition?

So the reason why I'm asking this.. I'm just some random guy who did 0 lines of code for the project at this point right so who am I really. Having that said, I would like to put effort in this project making a change and to do that, I would like to know that the vision is right. I also noticed the react dashboard is already quite far as in terms of functionality. What about "moderner" dashboards like this one which is open-source or some other cool open-source dashboard that gives it a new look and feel? I understand this is a risk, but it can also bring the product to the next level which is something I would like to work on but it's depending on the vision of the devs.

I don't want to step on toes here, just figuring out vision and strategy. :slight_smile:

Honestly there's nothing that's out of the realm of discussion. @PromoFaux (And X, but I don't think he's on Discourse?)

I'm moving this out of Beta 5's topic since it's not really the right place.

The latter. Which is the reason it's planned for a major version number bump due to being a breaking change.

Putting the HTTP API into FTL allows us to be webserver agnostic, as FTL can just serve the web panel.

As for design choices, as Dan said, there's nothing that is out of the realm of discussion. The current design of the next-gen panel is just based on the existing one, and the existing one uses AdminLTE UI framework because that's just what was chosen at the time that project was started.

Contributions are always welcome

1 Like

We used AdminLTE for the original template and that look has become part of Pi-hole's identity. We still get people telling us when they see that template in other projects, they think someone else is using our code.

I'd like to say that there was some grand design but it's mostly just iterating on the original. My personal experience is that any change will result in a tsunami of "THIS SUCKS! YOU KILLED PI-HOLE! DID A MONKEY DESIGN THIS GARBAGE?!??!?!" so I just stay with what we have.

Just look at what happened with Reddit's redesign. Personally I like it, but a lot of people are very salty about it. I feel for their design team.

I rarely use the web interface, I'm CLI over SSH. But I would like a modern look that isn't quite as "janky" as what we have now. Whether that is CSS changes and styling the layout we have now or redesigning completely is good for discussion for me.

I like the existing Pi-hole look. Clearly a Pi-hole when you see the screen. The tidying up with V5 movement to columns on the charts is an improvement that makes it both easier to read and a more modern look.

The interface is functional and fairly easy to use. I don't think we should chase modern solely because it is new.

I hear a number of people that have changed to AdGuard Home purely because their interface looks "newer" and it gives them the feels that it's more maintained and newer. It may not be any more functional than Pi-hole but users are fickle.

Plus, they get "acceptable ads" included in the package.

Ofcourse this is very true, there are simply 2 ways at looking at this. I can't name you a single product that didn't had users saying "o no I hate the new design". :stuck_out_tongue: Some "loud voiced" people don't like change but most of them will adjust and like the new GUI in the end. The question is if that should stop you from ever making changes on the product if you are scared that people will not like it.

I personally think that you can't stay in the past. Windows also updated their GUI a couple of times when people said "don't do it! we like the windows 98 / xp / windows 7 feeling". Almost every large company decides to update their GUI at some time, to make it more in line with the modern look-and-feel. The stakes are super high but they still do it. I don't think pi-hole is at the GUI is already at the top of it game. It's like windows xp, people like it because it works well, but it looks and feels old.

The risk of people not liking a new GUI can be mitigated quite good. So for example you can release the new dashboard first in a transition period, collect feedback from the community and most importantly work agile. I think the not working agile strategy is the biggest problem you guys have on the new react dashboard. It's aiming for a big-bang full release (not agile) besides that it's trying achieve to create an old design with new tech which I think is weird. In a transition period you can support both versions for a while and do a hard switch over when people like the new GUI enough.

So it's good to share thoughts on this subject right? I'm passing this project tho if there is no unanimous decision on a modern GUI and the strategy is to stay at the current GUI while working waterfall.

I was thinking no a new strategy like so:

  • Pick a new dashboard design that matches modern expectations.
  • Use the current codebase that is there already (react, redux) and convert it to the new dashboard.
  • Implement the log-in system properly on a working pi-hole installation.
  • Merge with master and include in an official release hidden away.
  • Done with first milestone.

Then for the next milestones decide what functionality should be ported in what milestone and bring every milestone to master (production) so people can use it on the latest updated branch as alternative for the existing dashboard. If the progress is far enough you can point to the new dashboard and let people use it to collect feedback.

Yes, very much so!

The existing code is all pre-MVC at this point.

Keep in mind that we are a team of part-time/spare-time developers. We don't have paid staff, we do what we can, when we can. Using methodologies like agile/scrumm/kanban isn't a great fit for us. Focusing time and talent on defining processes to development instead of actually developing ends up delaying everything.

1 Like

I also don't like the "management talk" but you can't completely without it. :slight_smile: I see that the react stuff is already going on for quite a long time now (looking at the commits) and yet 0% is in production so there is no user value after all that work. This is the result of the strategy.

The way you guys are working with production releases is quite agile as in terms of how fast and often fixes and improvements are released on production. If this flow can be there on a new beta web panel as well, I would like to reserve some hours every day (next to my job) to build something awesome for the users. Without support for this way of working I'm not burning my fingers on this.

Hope you have a nice sunday Dan, I'm donating a beer to the project.

2 Likes

Likely once we get the 5.0 released (hopefully this week, but don't quote me on that! :wink:), and after the inevitable couple of small point releases, the focus will shift to 6.0, and thus the new web interface and API, and once that it in a suitable state we can start a more public trial of that, too.

Technically one could check out the relevant branches and run it all now, but I wouldn't recommend it just yet, it likely isn't production-ready, and what limited time we all have at the moment is focussed on getting 5.0 out of the door

1 Like

(:heart_eyes:) :speak_no_evil: :shushing_face:

1 Like