Local .ics file access error
I tried to access a local .ics file with the default calendar module. When I use an external URL within the calendar’s configuration there is no problem - the calendar entries are displayed on my magic mirror.
If I download the same file and copy it into my magic mirror directory and change the calendar’s configuration to
URL: "http://IP_of_MM:8080/file.ics") the calendar module does not show any entries. I tried both putting the file into the magic mirror’s root directory (like @Sean mentioned in topic 9092) and putting into a subdirectory (like @Shockwave mentioned in topic 467) but I did not succeed yet.
When I try to access the file directly by entering the config’s URL into a browser (on another PC within the same network) I always get an error like “cannot get file.ics”; when quitting the magic mirror there are access errors / 404 errors displayed as well.
Hence to my mind it is some kind of access / authorization error…?!?
Any hints appreciated. Thanks a lot.
May the code be with you
Should be like this .
Thanks a lot, @lolo
Unfortunately this does not make any difference… using
webcal://...displays “no appointments” within the calendar as well. The MM’s log says “Calendar error. Could not fetch calendar … 404: Not found”.
I have local calendar and is working fine.
Copy file.ics in modules folder and add to config
Thanks a lot @lolo - you made my day!
That was the crucial point: the modules directory. I now can access the file via
Thanks a lot again!!!
@kai as @lolo suggested the files will be accessible if it is in modules directory. Not all files on root level are accessible directly. Below directories and their child directories and files are accessible from browser.
"/config", "/css", "/fonts", "/modules", "/vendor", "/translations", "/tests/configs"
Thank you very much @ashishtank for sharing this!
Good to know!