compatibility with local sites in /var/www

Hello, I find it a good idea and the concept of s… It is easy to use and understand. does anyone know if it is compatible with sites hosted locally in /var/www? and with mariadb databases? I had installed a few small sites for local testing with database connection, without having made any major changes to the computer have disappeared. Thank you

I understand you want to synchronize web pages (HTML files, etc.) between different hosts? That should be possible with Syncthing, just need to find a sane model how the Syncthing process gets access to the filed. Probably add the user who is supposed to run the Synchting service to the www-data group or similar.

Syncing databases with Synchting is probably a terrible idea, at least while the MariaDB server is running on either side. You could automate taking down the DB server, copying the underlying files to a Syncthing share, and restarting the server, via a regularly running script, if short downtimes are acceptable. Do the same (opposite copy direction) on the receiving end(s).

But I think there are better ways to operate replicated SQL databases.

Hello André. Thank you for your time. I don’t think I have explained myself clearly. I will do it by points:

  • I installed locally the LAMP
  • I created some files that I put in /var/www/html
  • I created a database that I accessed with the files that I had in /var/www/html.
  • I used the above for a long time and it worked fine.
  • A few months ago I installed Syncthing
  • Now in the /var/www/html folder I only see a generic html file and I have no database.

Since the last time I accessed the local site and now that I have detected it the most important change has been to install Syncthing

I have not detected it at the same time due to changes in the work routine that allowed me to test on a remote server.

I do not want to synchronize the data of that folder /var/www/html, only that they work without incompatibilities between them and if possible to recover the previous configuration of both the apache server and the database.

Syncthing has nothing to do with Apache / LAMP or /var/www whatsoever. It uses its own completely independent web server for its interface.

I think your connection between the folder being empty and installing Syncthing is a red herring, especially if you didn’t set up Syncthing to sync that path at all.

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.