diff --git a/README.md b/README.md index 91d1996..968972d 100644 --- a/README.md +++ b/README.md @@ -19,6 +19,8 @@ A public demo instance is available here: πŸ‘‰ https://guide.demo.johnnybegood.fr/ +Health page: https://guide.demo.johnnybegood.fr/health.php +Setup page (read only on demo): https://guide.demo.johnnybegood.fr/setup.php This demo runs with sample XMLTV feeds to showcase the interface. @@ -45,6 +47,7 @@ This demo runs with sample XMLTV feeds to showcase the interface. - βš™οΈ **Re-editable setup** β€” protected by an admin key, no SSH required to update config - 🩺 **Admin health page** β€” check config, XMLTV, M3U, response times, and metadata coverage - πŸ–¨οΈ **24h printable export** β€” generate a polished daily schedule for PDF/print and PNG export +- πŸ§ͺ **Demo mode** β€” drop a `.demo` file at the project root to expose admin pages safely in read-only mode - πŸ”” **Update notifications** β€” a badge appears in the topbar when a new release is available on GitHub - πŸ”„ **Auto-reload** EPG every 30 minutes - 0️⃣ **Zero build tooling** β€” vanilla PHP/JS/CSS, with bundled local assets @@ -234,6 +237,8 @@ http://guide.your-domain.com/health.php http://guide.your-domain.com/export.php ``` +`health.php` is admin-only by default. `export.php` is public so visitors can print or save the daily guide. + ---
@@ -280,6 +285,88 @@ nano /var/www/gridtv/config.json
+
+Health page + +## 🩺 Health page + +The health page gives you a quick operational view of your instance without needing SSH first: + +- checks whether `config.json` exists and is writable by PHP +- shows the current PHP version and whether `php-curl` / `php-xml` are loaded +- tests each configured XMLTV source +- tests each configured M3U playlist when present +- shows response times, final URL after redirects, content type, and basic metadata counts +- highlights XMLTV coverage for things like `category`, `sub-title`, `rating`, and `date` + +By default, the page is protected by the same admin key as `setup.php`: + +```text +http://guide.your-domain.com/health.php +``` + +If you enable demo mode with a `.demo` file, visitors can open the page without the key. + +--- + +
+ +
+24h export + +## πŸ–¨οΈ 24h export + +The export page builds a printable 24-hour TV guide from the current XMLTV source: + +- filter by source +- choose the target date +- restrict the export to a time window (`00h-24h`, morning, afternoon, evening, prime time) +- limit the number of visible channels +- choose between a readable card layout or a dense timeline +- export to PDF via the browser print dialog +- export to PNG directly from the page + +Public URL: + +```text +http://guide.your-domain.com/export.php +``` + +This page is intentionally public so you can share a β€œTV guide sheet” with other people. + +--- + +
+ +
+Demo mode + +## πŸ§ͺ Demo mode + +If you want to expose your instance publicly without letting visitors modify it, create an empty `.demo` file at the project root: + +```bash +touch /var/www/gridtv/.demo +``` + +When `.demo` exists: + +- `setup.php` becomes read-only +- `health.php` can be viewed without entering the admin key +- visitors can inspect the current configuration safely + +To disable demo mode: + +```bash +rm /var/www/gridtv/.demo +``` + +> `.demo` is ignored by Git, just like `config.json`. + +--- + +
+
Project structure @@ -295,7 +382,7 @@ gridtv/ β”œβ”€β”€ version.json # Current version (used for update check) β”œβ”€β”€ Dockerfile β”œβ”€β”€ docker-compose.yml -β”œβ”€β”€ .gitignore # config.json excluded +β”œβ”€β”€ .gitignore # local instance files excluded β”œβ”€β”€ locales/ # i18n translation files β”‚ β”œβ”€β”€ en.json β”‚ β”œβ”€β”€ fr.json